@@ -14,9 +14,9 @@ |
||
| 14 | 14 | use |
| 15 | 15 | cs\Core; |
| 16 | 16 | |
| 17 | -require DIR.'/core/loader_base.php'; //Inclusion of loader base |
|
| 17 | +require DIR.'/core/loader_base.php'; //Inclusion of loader base |
|
| 18 | 18 | @ini_set('error_log', LOGS.'/Http_server.log'); |
| 19 | -require __DIR__.'/functions.php'; //Inclusion of functions needed for http server |
|
| 19 | +require __DIR__.'/functions.php'; //Inclusion of functions needed for http server |
|
| 20 | 20 | require DIR.'/core/functions_global.php'; |
| 21 | 21 | /** |
| 22 | 22 | * Including of custom files |
@@ -1,11 +1,11 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * @package Http server |
|
| 4 | - * @category modules |
|
| 5 | - * @author Nazar Mokrynskyi <[email protected]> |
|
| 6 | - * @copyright Copyright (c) 2015-2016, Nazar Mokrynskyi |
|
| 7 | - * @license MIT License, see license.txt |
|
| 8 | - */ |
|
| 3 | + * @package Http server |
|
| 4 | + * @category modules |
|
| 5 | + * @author Nazar Mokrynskyi <[email protected]> |
|
| 6 | + * @copyright Copyright (c) 2015-2016, Nazar Mokrynskyi |
|
| 7 | + * @license MIT License, see license.txt |
|
| 8 | + */ |
|
| 9 | 9 | use |
| 10 | 10 | cs\modules\Http_server\Request; |
| 11 | 11 | |
@@ -25,8 +25,8 @@ discard block |
||
| 25 | 25 | } |
| 26 | 26 | require_once __DIR__.'/custom_loader.php'; |
| 27 | 27 | /** |
| 28 | - * Manually require composer autoloader because otherwise it will be included much later |
|
| 29 | - */ |
|
| 28 | + * Manually require composer autoloader because otherwise it will be included much later |
|
| 29 | + */ |
|
| 30 | 30 | require_once STORAGE.'/Composer/vendor/autoload.php'; |
| 31 | 31 | $loop = React\EventLoop\Factory::create(); |
| 32 | 32 | $socket = new React\Socket\Server($loop); |
@@ -51,8 +51,7 @@ discard block |
||
| 51 | 51 | * |
| 52 | 52 | * @throws ExitException |
| 53 | 53 | */ |
| 54 | - function init ($server, $query, $data, $data_stream, $cookie, $files, $request_started) { |
|
| 55 | - ++static::$request_id; |
|
| 54 | + function init ($server, $query, $data, $data_stream, $cookie, $files, $request_started) {++static::$request_id; |
|
| 56 | 55 | $this->init_server($server); |
| 57 | 56 | $this->init_query($query); |
| 58 | 57 | $this->init_data_and_files($data, $files, $data_stream); |
@@ -66,8 +65,7 @@ discard block |
||
| 66 | 65 | * |
| 67 | 66 | * @throws ExitException |
| 68 | 67 | */ |
| 69 | - function init_from_globals () { |
|
| 70 | - ++static::$request_id; |
|
| 68 | + function init_from_globals () {++static::$request_id; |
|
| 71 | 69 | // Hack: we override `$_SERVER` with iterator object, so conversion from iterator to an array is needed |
| 72 | 70 | $this->init_server(iterator_to_array($_SERVER)); |
| 73 | 71 | $this->init_query($_GET); |