summaryrefslogtreecommitdiff
path: root/it.class
diff options
context:
space:
mode:
authorChristian Helbling2017-02-07 16:54:52 +0100
committerChristian Helbling2017-02-07 16:54:52 +0100
commite5aac2298465e3b78398af5b17198bc527ca3d33 (patch)
tree3961eab1e50cf44406a0ec9ec257c3fd51647fb3 /it.class
parentf82923f96c15e957f4265f21597cd2cdc994482f (diff)
downloaditools-e5aac2298465e3b78398af5b17198bc527ca3d33.tar.gz
itools-e5aac2298465e3b78398af5b17198bc527ca3d33.tar.bz2
itools-e5aac2298465e3b78398af5b17198bc527ca3d33.zip
allow .time-1527 and .time-152715 as time formats for time debug parameter, add more tests for it::time()
Diffstat (limited to 'it.class')
-rw-r--r--it.class2
1 files changed, 1 insertions, 1 deletions
diff --git a/it.class b/it.class
index 34f0bf6..55d57db 100644
--- a/it.class
+++ b/it.class
@@ -901,7 +901,7 @@ static function gets()
*/
static function time()
{
- return ($t = EDC('time')) ? strtotime(rtrim(it::replace(array('(\d\d\d\d)-(\d\d)-(\d\d)-(\d\d)-(\d\d)(-(\d\d))?' => '$1-$2-$3 $4:$5:$7', '^(\d\d)-(\d\d)(-(\d\d))?' => 'today $1:$2:$4'), $t), ":")) : time();
+ return ($t = EDC('time')) ? strtotime(rtrim(it::replace(array('(\d\d\d\d)-(\d\d)-(\d\d)-(\d\d)-(\d\d)(-(\d\d))?' => '$1-$2-$3 $4:$5:$7', '^(\d\d)-?(\d\d)(-?(\d\d))?$' => 'today $1:$2:$4'), $t), ":")) : time();
}
/**