include ->args in options so that 'now' can be passed to the object constructor
authorChuck Hagenbuch <chuck@horde.org>
Mon, 4 May 2009 01:37:40 +0000 (21:37 -0400)
committerChuck Hagenbuch <chuck@horde.org>
Mon, 4 May 2009 01:37:40 +0000 (21:37 -0400)
framework/Date_Parser/lib/Horde/Date/Parser/Locale/Base.php

index 526b9fd..ee7aa49 100644 (file)
@@ -3,6 +3,7 @@ class Horde_Date_Parser_Locale_Base
 {
     public $definitions = array();
     public $args = array();
+    public $now;
 
     public function __construct($args)
     {
@@ -57,7 +58,7 @@ class Horde_Date_Parser_Locale_Base
             'guess' => true,
             'ambiguousTimeRange' => 6,
         );
-        $options = array_merge($defaultOptions, $specifiedOptions);
+        $options = array_merge($defaultOptions, $this->args, $specifiedOptions);
 
         // ensure the specified options are valid
         foreach (array_keys($specifiedOptions) as $key) {