File tree Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Original file line number Diff line number Diff line change @@ -31,20 +31,28 @@ public function __construct($appenv)
31
31
}
32
32
33
33
/**
34
- * Create a Symfony application
34
+ * Create a Laravel application
35
35
*/
36
36
public function getApplication ()
37
37
{
38
- if ( file_exists ( __DIR__ . ' /autoload.php ' ) && file_exists ( __DIR__ . ' /start.php ' )) {
39
- require_once __DIR__ . ' /autoload .php ';
40
- $ this ->app = require_once __DIR__ . ' /start .php ' ;
38
+ // Laravel 5 / Lumen
39
+ if ( file_exists ( ' bootstrap/app .php ')) {
40
+ return $ this ->app = require_once ' bootstrap/app .php ' ;
41
41
}
42
42
43
- return $ this ->app ;
43
+ // Laravel 4
44
+ if (file_exists ('bootstrap/start.php ' )) {
45
+ require_once 'bootstrap/autoload.php ' ;
46
+ return $ this ->app = require_once 'bootstrap/start.php ' ;
47
+ }
48
+
49
+ throw new \RuntimeException ('Laravel bootstrap file not found ' );
44
50
}
45
51
46
52
/**
47
53
* Return the StackPHP stack.
54
+ * @param Builder $stack
55
+ * @return Builder
48
56
*/
49
57
public function getStack (Builder $ stack )
50
58
{
You can’t perform that action at this time.
0 commit comments