@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | throw new Exception(Controller::GENERIC_ERROR, 63); |
46 | 46 | } |
47 | 47 | // We kindly provide the remaining time before expiration (in seconds) |
48 | - $data->meta->remaining_time = $data->meta->expire_date - time(); |
|
48 | + $data->meta->remaining_time = $data->meta->expire_date-time(); |
|
49 | 49 | } |
50 | 50 | |
51 | 51 | // check if non-expired burn after reading paste needs to be deleted |
@@ -232,7 +232,7 @@ discard block |
||
232 | 232 | $expire = $this->_conf->getKey($this->_conf->getKey('default', 'expire'), 'expire_options'); |
233 | 233 | } |
234 | 234 | if ($expire > 0) { |
235 | - $this->_data->meta->expire_date = time() + $expire; |
|
235 | + $this->_data->meta->expire_date = time()+$expire; |
|
236 | 236 | } |
237 | 237 | } |
238 | 238 |
@@ -111,14 +111,14 @@ |
||
111 | 111 | // purge file of expired hashes to keep it small |
112 | 112 | $now = time(); |
113 | 113 | foreach ($tl as $key => $time) { |
114 | - if ($time + self::$_limit < $now) { |
|
114 | + if ($time+self::$_limit < $now) { |
|
115 | 115 | unset($tl[$key]); |
116 | 116 | } |
117 | 117 | } |
118 | 118 | |
119 | 119 | // this hash is used as an array key, hence a shorter algo is used |
120 | 120 | $hash = self::getHash('sha256'); |
121 | - if (array_key_exists($hash, $tl) && ($tl[$hash] + self::$_limit >= $now)) { |
|
121 | + if (array_key_exists($hash, $tl) && ($tl[$hash]+self::$_limit >= $now)) { |
|
122 | 122 | $result = false; |
123 | 123 | } else { |
124 | 124 | $tl[$hash] = time(); |
@@ -75,7 +75,7 @@ |
||
75 | 75 | if (self::_exists($file)) { |
76 | 76 | require self::getPath($file); |
77 | 77 | $pl = $GLOBALS['purge_limiter']; |
78 | - if ($pl + self::$_limit >= $now) { |
|
78 | + if ($pl+self::$_limit >= $now) { |
|
79 | 79 | return false; |
80 | 80 | } |
81 | 81 | } |