@@ -111,7 +111,7 @@ discard block |
||
| 111 | 111 | public function requestTime() |
| 112 | 112 | { |
| 113 | 113 | if (!isset($this->requestTime)) { |
| 114 | - $this->requestTime = microtime(true) - $this->getRequest()->server->get('REQUEST_TIME_FLOAT'); |
|
| 114 | + $this->requestTime = microtime(true)-$this->getRequest()->server->get('REQUEST_TIME_FLOAT'); |
|
| 115 | 115 | } |
| 116 | 116 | |
| 117 | 117 | return $this->requestTime; |
@@ -674,15 +674,15 @@ discard block |
||
| 674 | 674 | |
| 675 | 675 | if ($seconds >= 86400) { |
| 676 | 676 | // Over a day |
| 677 | - $val = (int) floor($seconds / 86400); |
|
| 677 | + $val = (int)floor($seconds / 86400); |
|
| 678 | 678 | $key = 'days'; |
| 679 | 679 | } elseif ($seconds >= 3600) { |
| 680 | 680 | // Over an hour, less than a day |
| 681 | - $val = (int) floor($seconds / 3600); |
|
| 681 | + $val = (int)floor($seconds / 3600); |
|
| 682 | 682 | $key = 'hours'; |
| 683 | 683 | } elseif ($seconds >= 60) { |
| 684 | 684 | // Over a minute, less than an hour |
| 685 | - $val = (int) floor($seconds / 60); |
|
| 685 | + $val = (int)floor($seconds / 60); |
|
| 686 | 686 | $key = 'minutes'; |
| 687 | 687 | } |
| 688 | 688 | |
@@ -72,7 +72,7 @@ discard block |
||
| 72 | 72 | } |
| 73 | 73 | |
| 74 | 74 | // Find the path, and complain if English doesn't exist. |
| 75 | - $path = $this->container->getParameter('kernel.root_dir') . '/../i18n'; |
|
| 75 | + $path = $this->container->getParameter('kernel.root_dir').'/../i18n'; |
|
| 76 | 76 | if (!file_exists("$path/en.json")) { |
| 77 | 77 | throw new Exception("Language directory doesn't exist: $path"); |
| 78 | 78 | } |
@@ -127,7 +127,7 @@ discard block |
||
| 127 | 127 | $messageFiles = glob($this->container->getParameter('kernel.root_dir').'/../i18n/*.json'); |
| 128 | 128 | |
| 129 | 129 | $languages = array_values(array_unique(array_map( |
| 130 | - function ($filename) { |
|
| 130 | + function($filename) { |
|
| 131 | 131 | return basename($filename, '.json'); |
| 132 | 132 | }, |
| 133 | 133 | $messageFiles |