@@ -109,9 +109,9 @@ |
||
109 | 109 | */ |
110 | 110 | protected function getFilePath($fileName) { |
111 | 111 | if (strpos($fileName, 'http://') !== false || strpos($fileName, 'https://') !== false) { |
112 | - try{ |
|
112 | + try { |
|
113 | 113 | $current = file_get_contents($fileName); |
114 | - } catch(\Exception $e) { |
|
114 | + } catch (\Exception $e) { |
|
115 | 115 | throw new DeCaptchaErrors(DeCaptchaErrors::ERROR_FILE_IS_NOT_LOADED, $fileName, $this->errorLang); |
116 | 116 | } |
117 | 117 | $path = tempnam(sys_get_temp_dir(), 'captcha'); |
@@ -138,14 +138,14 @@ |
||
138 | 138 | $this->assertTrue(abs($timePassed - 0.25) < 0.035); |
139 | 139 | |
140 | 140 | $start = microtime(true); |
141 | - $bound(0.15, function () { |
|
141 | + $bound(0.15, function() { |
|
142 | 142 | sleep(0.2); |
143 | 143 | }); |
144 | 144 | $bound(0.3); |
145 | 145 | $timePassed = microtime(true) - $start; |
146 | 146 | $this->assertTrue(abs($timePassed - 0.45) < 0.035); |
147 | 147 | |
148 | - $this->assertEquals(2, $bound(0, function () { |
|
148 | + $this->assertEquals(2, $bound(0, function() { |
|
149 | 149 | return 2; |
150 | 150 | })); |
151 | 151 | $this->assertEquals(null, $bound(0)); |