summaryrefslogtreecommitdiff
path: root/framework/Util/TSimpleDateFormatter.php
diff options
context:
space:
mode:
authorctrlaltca <>2013-01-06 19:16:09 +0000
committerctrlaltca <>2013-01-06 19:16:09 +0000
commitea00eb2ea27613491eb517be9659059696fb335b (patch)
tree57c1ce76ec17816effe67a1a8ae7b8500a5073aa /framework/Util/TSimpleDateFormatter.php
parentb5f4be7ea0b8bdf220297893a907fe59c017fbd5 (diff)
backpotder r3238, r3239 to trunk/
Diffstat (limited to 'framework/Util/TSimpleDateFormatter.php')
-rw-r--r--framework/Util/TSimpleDateFormatter.php11
1 files changed, 2 insertions, 9 deletions
diff --git a/framework/Util/TSimpleDateFormatter.php b/framework/Util/TSimpleDateFormatter.php
index 8b17048a..a1a1842a 100644
--- a/framework/Util/TSimpleDateFormatter.php
+++ b/framework/Util/TSimpleDateFormatter.php
@@ -173,15 +173,8 @@ class TSimpleDateFormatter
*/
private function getDate($value)
{
- if(!is_string($value))
- {
- $s = Prado::createComponent('System.Util.TDateTimeStamp');
- return $s->getDate($value);
- }
- $date = @strtotime($value);
- if($date < 0)
- throw new TInvalidDataValueException('invalid_date', $value);
- return @getdate($date);
+ $s = Prado::createComponent('System.Util.TDateTimeStamp');
+ return $s->parseDate($value);
}
/**