Changeset 2675 for trunk/system/libraries/Calendar_Event.php
- Timestamp:
- 05/15/2008 02:22:13 PM (6 months ago)
- Files:
-
- 1 modified
-
trunk/system/libraries/Calendar_Event.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/system/libraries/Calendar_Event.php
r2598 r2675 11 11 */ 12 12 class Calendar_Event_Core extends Event_Observer { 13 14 // Boolean conditions 15 protected $booleans = array 16 ( 17 'current', 18 'weekend', 19 'first_day', 20 'last_day', 21 'last_occurrence', 22 'easter', 23 ); 13 24 14 25 // Rendering conditions … … 54 65 else 55 66 { 67 if ($key === 'callback') 68 { 69 // Do nothing 70 } 71 elseif (in_array($key, $this->booleans)) 72 { 73 // Make the value boolean 74 $value = (bool) $value; 75 } 76 else 77 { 78 // Make the value an int 79 $value = (int) $value; 80 } 81 56 82 $this->conditions[$key] = $value; 57 83 }
