mirror of
https://github.com/flextype/flextype.git
synced 2025-08-10 15:14:20 +02:00
feat(console): move event onFlextypeConsoleBeforeRun
to flextype boot file #543
This commit is contained in:
@@ -22,9 +22,7 @@ class FlextypeConsoleApplication extends ConsoleApplication
|
||||
// Add Console Commands
|
||||
console()->add(new EntriesCreateCommand());
|
||||
console()->add(new EntriesDeleteCommand());
|
||||
|
||||
// Run Flextype Console Application
|
||||
emitter()->emit('onFlextypeConsoleBeforeRun');
|
||||
|
||||
parent::run();
|
||||
}
|
||||
}
|
@@ -401,6 +401,7 @@ app()->add(new WhoopsMiddleware([
|
||||
|
||||
// Run Flextype Application
|
||||
if (php_sapi_name() === 'cli') {
|
||||
emitter()->emit('onFlextypeConsoleBeforeRun');
|
||||
console()->run();
|
||||
} else {
|
||||
emitter()->emit('onFlextypeBeforeRun');
|
||||
|
Reference in New Issue
Block a user