File tree Expand file tree Collapse file tree 2 files changed +13
-4
lines changed
Expand file tree Collapse file tree 2 files changed +13
-4
lines changed Original file line number Diff line number Diff line change 11#!/usr/bin/env php
22<?php
33
4- require (dirname (__DIR__ ) . "/vendor/autoload.php " );
4+ $ autoloadPath = dirname (__DIR__ ) . "/autoload.php " ;
5+ if (!file_exists ($ autoloadPath )) {
6+ $ autoloadPath =dirname (__DIR__ ) . "/vendor/autoload.php " ;
7+ }
8+ require ($ autoloadPath );
59
610set_time_limit (0 );
711ini_set ('memory_limit ' , '2048M ' );
Original file line number Diff line number Diff line change @@ -5,10 +5,15 @@ use React\Http\Response;
55use React \Http \Request ;
66use Application \HTTP \App ;
77
8- define ("ROOT " , dirname (__DIR__ ));
8+ $ autoloadPath = dirname (__DIR__ ) . "/autoload.php " ;
9+ $ configPath = dirname (__DIR__ ) . "/mkusher/padawan/app/config/bin.php " ;
10+ if (!file_exists ($ autoloadPath )) {
11+ $ autoloadPath = dirname (__DIR__ ) . "/vendor/autoload.php " ;
12+ $ configPath = dirname (__DIR__ ) . "/app/config/bin.php " ;
13+ }
914
10- require ROOT . " /app/config/bin.php " ;
11- require ROOT . " /vendor/autoload.php " ;
15+ require ( $ configPath ) ;
16+ require ( $ autoloadPath ) ;
1217
1318$ noFsIO = false ;
1419$ port = 15155 ;
You can’t perform that action at this time.
0 commit comments