@@ -21,7 +21,7 @@ discard block |
||
21 | 21 | |
22 | 22 | public static function getInfo($patcher, $backtrace) |
23 | 23 | { |
24 | - if (! isset(self::$map[$patcher])) |
|
24 | + if ( ! isset(self::$map[$patcher])) |
|
25 | 25 | { |
26 | 26 | throw new LogicException("No such a patcher: $patcher"); |
27 | 27 | } |
@@ -41,12 +41,12 @@ discard block |
||
41 | 41 | $line = isset($backtrace[$offset]['line']) |
42 | 42 | ? $backtrace[$offset]['line'] : null; |
43 | 43 | |
44 | - if (isset($backtrace[$offset+2])) |
|
44 | + if (isset($backtrace[$offset + 2])) |
|
45 | 45 | { |
46 | - $class = isset($backtrace[$offset+2]['class']) |
|
47 | - ? $backtrace[$offset+2]['class'] |
|
46 | + $class = isset($backtrace[$offset + 2]['class']) |
|
47 | + ? $backtrace[$offset + 2]['class'] |
|
48 | 48 | : null; |
49 | - $function = $backtrace[$offset+2]['function']; |
|
49 | + $function = $backtrace[$offset + 2]['function']; |
|
50 | 50 | } |
51 | 51 | else |
52 | 52 | { |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | if (isset($class)) |
58 | 58 | { |
59 | 59 | $method = $function; |
60 | - $class_method = $class . '::' . $function; |
|
60 | + $class_method = $class.'::'.$function; |
|
61 | 61 | $function = null; |
62 | 62 | } |
63 | 63 | else |
@@ -47,8 +47,7 @@ discard block |
||
47 | 47 | ? $backtrace[$offset+2]['class'] |
48 | 48 | : null; |
49 | 49 | $function = $backtrace[$offset+2]['function']; |
50 | - } |
|
51 | - else |
|
50 | + } else |
|
52 | 51 | { |
53 | 52 | $class = null; |
54 | 53 | $function = null; |
@@ -59,8 +58,7 @@ discard block |
||
59 | 58 | $method = $function; |
60 | 59 | $class_method = $class . '::' . $function; |
61 | 60 | $function = null; |
62 | - } |
|
63 | - else |
|
61 | + } else |
|
64 | 62 | { |
65 | 63 | $method = null; |
66 | 64 | $class_method = null; |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | |
11 | 11 | namespace Kenjis\MonkeyPatch\Patcher; |
12 | 12 | |
13 | -require __DIR__ . '/../Exception/ExitException.php'; |
|
13 | +require __DIR__.'/../Exception/ExitException.php'; |
|
14 | 14 | |
15 | 15 | class ExitPatcher |
16 | 16 | { |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | } |
31 | 31 | elseif ($token[0] === T_EXIT) |
32 | 32 | { |
33 | - if ($tokens[$i+1] === ';') |
|
33 | + if ($tokens[$i + 1] === ';') |
|
34 | 34 | { |
35 | 35 | $new_source .= 'exit__()'; |
36 | 36 | } |
@@ -27,20 +27,17 @@ |
||
27 | 27 | if (is_string($token)) |
28 | 28 | { |
29 | 29 | $new_source .= $token; |
30 | - } |
|
31 | - elseif ($token[0] === T_EXIT) |
|
30 | + } elseif ($token[0] === T_EXIT) |
|
32 | 31 | { |
33 | 32 | if ($tokens[$i+1] === ';') |
34 | 33 | { |
35 | 34 | $new_source .= 'exit__()'; |
36 | - } |
|
37 | - else |
|
35 | + } else |
|
38 | 36 | { |
39 | 37 | $new_source .= 'exit__'; |
40 | 38 | } |
41 | 39 | $patched = true; |
42 | - } |
|
43 | - else |
|
40 | + } else |
|
44 | 41 | { |
45 | 42 | $new_source .= $token[1]; |
46 | 43 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -10,8 +10,8 @@ |
||
10 | 10 | |
11 | 11 | namespace Kenjis\MonkeyPatch\Patcher; |
12 | 12 | |
13 | -require __DIR__ . '/FunctionPatcher/NodeVisitor.php'; |
|
14 | -require __DIR__ . '/FunctionPatcher/Proxy.php'; |
|
13 | +require __DIR__.'/FunctionPatcher/NodeVisitor.php'; |
|
14 | +require __DIR__.'/FunctionPatcher/Proxy.php'; |
|
15 | 15 | |
16 | 16 | use LogicException; |
17 | 17 |
@@ -173,13 +173,11 @@ |
||
173 | 173 | if (is_string($token)) |
174 | 174 | { |
175 | 175 | $new_source .= $token; |
176 | - } |
|
177 | - elseif ($i == $replacement['key']) |
|
176 | + } elseif ($i == $replacement['key']) |
|
178 | 177 | { |
179 | 178 | $new_source .= $replacement['value']; |
180 | 179 | $replacement = each(self::$replacement); |
181 | - } |
|
182 | - else |
|
180 | + } else |
|
183 | 181 | { |
184 | 182 | $new_source .= $token[1]; |
185 | 183 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -10,8 +10,8 @@ discard block |
||
10 | 10 | |
11 | 11 | namespace Kenjis\MonkeyPatch\Patcher; |
12 | 12 | |
13 | -require __DIR__ . '/MethodPatcher/NodeVisitor.php'; |
|
14 | -require __DIR__ . '/MethodPatcher/PatchManager.php'; |
|
13 | +require __DIR__.'/MethodPatcher/NodeVisitor.php'; |
|
14 | +require __DIR__.'/MethodPatcher/PatchManager.php'; |
|
15 | 15 | |
16 | 16 | use LogicException; |
17 | 17 | |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | { |
56 | 56 | if ($start_method && $token === '{') |
57 | 57 | { |
58 | - $new_source .= '{ ' . self::CODE; |
|
58 | + $new_source .= '{ '.self::CODE; |
|
59 | 59 | $start_method = false; |
60 | 60 | $replacement = each(self::$replacement); |
61 | 61 | } |
@@ -58,13 +58,11 @@ |
||
58 | 58 | $new_source .= '{ ' . self::CODE; |
59 | 59 | $start_method = false; |
60 | 60 | $replacement = each(self::$replacement); |
61 | - } |
|
62 | - else |
|
61 | + } else |
|
63 | 62 | { |
64 | 63 | $new_source .= $token; |
65 | 64 | } |
66 | - } |
|
67 | - else |
|
65 | + } else |
|
68 | 66 | { |
69 | 67 | $new_source .= $token[1]; |
70 | 68 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -66,16 +66,16 @@ |
||
66 | 66 | $called_method = 'n/a'; |
67 | 67 | } |
68 | 68 | |
69 | - $log_args = function () use ($params) { |
|
69 | + $log_args = function() use ($params) { |
|
70 | 70 | $output = ''; |
71 | 71 | foreach ($params as $arg) { |
72 | - $output .= var_export($arg, true) . ', '; |
|
72 | + $output .= var_export($arg, true).', '; |
|
73 | 73 | } |
74 | 74 | $output = rtrim($output, ', '); |
75 | 75 | return $output; |
76 | 76 | }; |
77 | 77 | MonkeyPatchManager::log( |
78 | - 'invoke_method: ' . $class.'::'.$method . '(' . $log_args() . ') on line ' . $line . ' in ' . $file . ' by ' . $called_method |
|
78 | + 'invoke_method: '.$class.'::'.$method.'('.$log_args().') on line '.$line.' in '.$file.' by '.$called_method |
|
79 | 79 | ); |
80 | 80 | // var_dump($trace); exit; |
81 | 81 | } |
@@ -56,12 +56,10 @@ discard block |
||
56 | 56 | if (isset($info['class_method'])) |
57 | 57 | { |
58 | 58 | $called_method = $info['class_method']; |
59 | - } |
|
60 | - elseif (isset($info['function'])) |
|
59 | + } elseif (isset($info['function'])) |
|
61 | 60 | { |
62 | 61 | $called_method = $info['function']; |
63 | - } |
|
64 | - else |
|
62 | + } else |
|
65 | 63 | { |
66 | 64 | $called_method = 'n/a'; |
67 | 65 | } |
@@ -88,8 +86,7 @@ discard block |
||
88 | 86 | ) |
89 | 87 | { |
90 | 88 | $patch = self::$patches[$class][$method]; |
91 | - } |
|
92 | - else |
|
89 | + } else |
|
93 | 90 | { |
94 | 91 | return __GO_TO_ORIG__; |
95 | 92 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -30,11 +30,11 @@ |
||
30 | 30 | $real_path = realpath($path); |
31 | 31 | if ($real_path === FALSE) |
32 | 32 | { |
33 | - throw new RuntimeException($path . ' does not exist?'); |
|
33 | + throw new RuntimeException($path.' does not exist?'); |
|
34 | 34 | } |
35 | 35 | if (is_dir($real_path)) |
36 | 36 | { |
37 | - $real_path = $real_path . '/'; |
|
37 | + $real_path = $real_path.'/'; |
|
38 | 38 | } |
39 | 39 | $new_paths[] = $real_path; |
40 | 40 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -11,16 +11,16 @@ |
||
11 | 11 | // Autoloader for PHP-Parser |
12 | 12 | // Don't use `require`, because we must require it in CIPHPUnitTest::init() |
13 | 13 | // for providing autoloading when we don't use Monkey Patching |
14 | -require_once __DIR__ . '/third_party/PHP-Parser/lib/bootstrap.php'; |
|
14 | +require_once __DIR__.'/third_party/PHP-Parser/lib/bootstrap.php'; |
|
15 | 15 | |
16 | -require __DIR__ . '/IncludeStream.php'; |
|
17 | -require __DIR__ . '/PathChecker.php'; |
|
18 | -require __DIR__ . '/MonkeyPatchManager.php'; |
|
19 | -require __DIR__ . '/MonkeyPatch.php'; |
|
20 | -require __DIR__ . '/Cache.php'; |
|
21 | -require __DIR__ . '/InvocationVerifier.php'; |
|
16 | +require __DIR__.'/IncludeStream.php'; |
|
17 | +require __DIR__.'/PathChecker.php'; |
|
18 | +require __DIR__.'/MonkeyPatchManager.php'; |
|
19 | +require __DIR__.'/MonkeyPatch.php'; |
|
20 | +require __DIR__.'/Cache.php'; |
|
21 | +require __DIR__.'/InvocationVerifier.php'; |
|
22 | 22 | |
23 | -require __DIR__ . '/functions/exit__.php'; |
|
23 | +require __DIR__.'/functions/exit__.php'; |
|
24 | 24 | |
25 | 25 | const __GO_TO_ORIG__ = '__GO_TO_ORIG__'; |
26 | 26 |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -18,11 +18,11 @@ |
||
18 | 18 | |
19 | 19 | if ($class === null) |
20 | 20 | { |
21 | - $message = 'exit() called in ' . $method . '() function'; |
|
21 | + $message = 'exit() called in '.$method.'() function'; |
|
22 | 22 | } |
23 | 23 | else |
24 | 24 | { |
25 | - $message = 'exit() called in ' . $class . '::' . $method . '()'; |
|
25 | + $message = 'exit() called in '.$class.'::'.$method.'()'; |
|
26 | 26 | } |
27 | 27 | |
28 | 28 | $exception_name = Kenjis\MonkeyPatch\MonkeyPatchManager::getExitExceptionClassname(); |
@@ -19,8 +19,7 @@ |
||
19 | 19 | if ($class === null) |
20 | 20 | { |
21 | 21 | $message = 'exit() called in ' . $method . '() function'; |
22 | - } |
|
23 | - else |
|
22 | + } else |
|
24 | 23 | { |
25 | 24 | $message = 'exit() called in ' . $class . '::' . $method . '()'; |
26 | 25 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Part of CI PHPUnit Test |
|
4 | - * |
|
5 | - * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | - * @license MIT License |
|
7 | - * @copyright 2015 Kenji Suzuki |
|
8 | - * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | - */ |
|
3 | + * Part of CI PHPUnit Test |
|
4 | + * |
|
5 | + * @author Kenji Suzuki <https://github.com/kenjis> |
|
6 | + * @license MIT License |
|
7 | + * @copyright 2015 Kenji Suzuki |
|
8 | + * @link https://github.com/kenjis/ci-phpunit-test |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | require __DIR__ . '/Installer.php'; |
12 | 12 |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | * Start the timer... tick tock tick tock... |
186 | 186 | * ------------------------------------------------------ |
187 | 187 | */ |
188 | - $BM =& load_class('Benchmark', 'core'); |
|
188 | + $BM = & load_class('Benchmark', 'core'); |
|
189 | 189 | $BM->mark('total_execution_time_start'); |
190 | 190 | $BM->mark('loading_time:_base_classes_start'); |
191 | 191 | |
@@ -194,7 +194,7 @@ discard block |
||
194 | 194 | * Instantiate the hooks class |
195 | 195 | * ------------------------------------------------------ |
196 | 196 | */ |
197 | - $EXT =& load_class('Hooks', 'core'); |
|
197 | + $EXT = & load_class('Hooks', 'core'); |
|
198 | 198 | |
199 | 199 | /* |
200 | 200 | * ------------------------------------------------------ |
@@ -213,7 +213,7 @@ discard block |
||
213 | 213 | * depending on another class that uses it. |
214 | 214 | * |
215 | 215 | */ |
216 | - $CFG =& load_class('Config', 'core'); |
|
216 | + $CFG = & load_class('Config', 'core'); |
|
217 | 217 | |
218 | 218 | // Do we have any manually set config items in the index.php file? |
219 | 219 | if (isset($assign_to_config) && is_array($assign_to_config)) |
@@ -291,28 +291,28 @@ discard block |
||
291 | 291 | * Instantiate the UTF-8 class |
292 | 292 | * ------------------------------------------------------ |
293 | 293 | */ |
294 | - $UNI =& load_class('Utf8', 'core'); |
|
294 | + $UNI = & load_class('Utf8', 'core'); |
|
295 | 295 | |
296 | 296 | /* |
297 | 297 | * ------------------------------------------------------ |
298 | 298 | * Instantiate the URI class |
299 | 299 | * ------------------------------------------------------ |
300 | 300 | */ |
301 | - $URI =& load_class('URI', 'core'); |
|
301 | + $URI = & load_class('URI', 'core'); |
|
302 | 302 | |
303 | 303 | /* |
304 | 304 | * ------------------------------------------------------ |
305 | 305 | * Instantiate the routing class and set the routing |
306 | 306 | * ------------------------------------------------------ |
307 | 307 | */ |
308 | - $RTR =& load_class('Router', 'core', isset($routing) ? $routing : NULL); |
|
308 | + $RTR = & load_class('Router', 'core', isset($routing) ? $routing : NULL); |
|
309 | 309 | |
310 | 310 | /* |
311 | 311 | * ------------------------------------------------------ |
312 | 312 | * Instantiate the output class |
313 | 313 | * ------------------------------------------------------ |
314 | 314 | */ |
315 | - $OUT =& load_class('Output', 'core'); |
|
315 | + $OUT = & load_class('Output', 'core'); |
|
316 | 316 | |
317 | 317 | /* |
318 | 318 | * ------------------------------------------------------ |
@@ -329,21 +329,21 @@ discard block |
||
329 | 329 | * Load the security class for xss and csrf support |
330 | 330 | * ----------------------------------------------------- |
331 | 331 | */ |
332 | - $SEC =& load_class('Security', 'core'); |
|
332 | + $SEC = & load_class('Security', 'core'); |
|
333 | 333 | |
334 | 334 | /* |
335 | 335 | * ------------------------------------------------------ |
336 | 336 | * Load the Input class and sanitize globals |
337 | 337 | * ------------------------------------------------------ |
338 | 338 | */ |
339 | - $IN =& load_class('Input', 'core'); |
|
339 | + $IN = & load_class('Input', 'core'); |
|
340 | 340 | |
341 | 341 | /* |
342 | 342 | * ------------------------------------------------------ |
343 | 343 | * Load the Language class |
344 | 344 | * ------------------------------------------------------ |
345 | 345 | */ |
346 | - $LANG =& load_class('Lang', 'core'); |
|
346 | + $LANG = & load_class('Lang', 'core'); |
|
347 | 347 | |
348 | 348 | /* |
349 | 349 | * ------------------------------------------------------ |
@@ -169,12 +169,10 @@ discard block |
||
169 | 169 | file_exists(APPPATH.'vendor/autoload.php') |
170 | 170 | ? require_once(APPPATH.'vendor/autoload.php') |
171 | 171 | : log_message('error', '$config[\'composer_autoload\'] is set to TRUE but '.APPPATH.'vendor/autoload.php was not found.'); |
172 | - } |
|
173 | - elseif (file_exists($composer_autoload)) |
|
172 | + } elseif (file_exists($composer_autoload)) |
|
174 | 173 | { |
175 | 174 | require_once($composer_autoload); |
176 | - } |
|
177 | - else |
|
175 | + } else |
|
178 | 176 | { |
179 | 177 | log_message('error', 'Could not find the specified $config[\'composer_autoload\'] path: '.$composer_autoload); |
180 | 178 | } |
@@ -250,8 +248,7 @@ discard block |
||
250 | 248 | // This is required for mb_convert_encoding() to strip invalid characters. |
251 | 249 | // That's utilized by CI_Utf8, but it's also done for consistency with iconv. |
252 | 250 | mb_substitute_character('none'); |
253 | - } |
|
254 | - else |
|
251 | + } else |
|
255 | 252 | { |
256 | 253 | define('MB_ENABLED', FALSE); |
257 | 254 | } |
@@ -264,8 +261,7 @@ discard block |
||
264 | 261 | // iconv.internal_encoding is deprecated starting with PHP 5.6 |
265 | 262 | // and it's usage triggers E_DEPRECATED messages. |
266 | 263 | @ini_set('iconv.internal_encoding', $charset); |
267 | - } |
|
268 | - else |
|
264 | + } else |
|
269 | 265 | { |
270 | 266 | define('ICONV_ENABLED', FALSE); |
271 | 267 | } |
@@ -405,16 +401,14 @@ discard block |
||
405 | 401 | if (empty($class) OR ! file_exists(APPPATH.'controllers/'.$RTR->directory.$class.'.php')) |
406 | 402 | { |
407 | 403 | $e404 = TRUE; |
408 | - } |
|
409 | - else |
|
404 | + } else |
|
410 | 405 | { |
411 | 406 | require_once(APPPATH.'controllers/'.$RTR->directory.$class.'.php'); |
412 | 407 | |
413 | 408 | if ( ! class_exists($class, FALSE) OR $method[0] === '_' OR method_exists('CI_Controller', $method)) |
414 | 409 | { |
415 | 410 | $e404 = TRUE; |
416 | - } |
|
417 | - elseif (method_exists($class, '_remap')) |
|
411 | + } elseif (method_exists($class, '_remap')) |
|
418 | 412 | { |
419 | 413 | $params = array($method, array_slice($URI->rsegments, 2)); |
420 | 414 | $method = '_remap'; |
@@ -456,8 +450,7 @@ discard block |
||
456 | 450 | $RTR->directory = ''; |
457 | 451 | } |
458 | 452 | } |
459 | - } |
|
460 | - else |
|
453 | + } else |
|
461 | 454 | { |
462 | 455 | $e404 = FALSE; |
463 | 456 | } |
@@ -473,8 +466,7 @@ discard block |
||
473 | 466 | 1 => $class, |
474 | 467 | 2 => $method |
475 | 468 | ); |
476 | - } |
|
477 | - else |
|
469 | + } else |
|
478 | 470 | { |
479 | 471 | show_404($RTR->directory.$class.'/'.$method); |
480 | 472 | } |