Skip to content
Permalink
Browse files

formatting

  • Loading branch information...
taylorotwell committed Jun 8, 2019
1 parent f849544 commit 9e20849e5cca7b98ebf0eee2b563b532ff6fe704
@@ -29,20 +29,22 @@ class DownCommand extends Command
/**
* Execute the console command.
*
* @return void
* @return int
*/
public function handle()
{
try {
file_put_contents(storage_path('framework/down'),
json_encode($this->getDownFilePayload(),
JSON_PRETTY_PRINT));
$this->comment('Application is now in maintenance mode.');
} catch (Exception $e) {
$this->error('Application is failed to enter maintenance mode.');
$this->error('Failed to enter maintenance mode.');
$this->error($e->getMessage());
return false;
return 1;
}
}
@@ -24,7 +24,7 @@ class UpCommand extends Command
/**
* Execute the console command.
*
* @return void
* @return int
*/
public function handle()
{
@@ -34,13 +34,16 @@ public function handle()
return true;
}
unlink(storage_path('framework/down'));
$this->info('Application is now live.');
} catch (Exception $e) {
$this->error('Application is failed to up.');
$this->error('Failed to disable maintenance mode.');
$this->error($e->getMessage());
return false;
return 1;
}
}
}

0 comments on commit 9e20849

Please sign in to comment.
You can’t perform that action at this time.