File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
src/Illuminate/Database/Console Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change 33namespace Illuminate \Database \Console ;
44
55use Illuminate \Console \Command ;
6+ use Illuminate \Console \Prohibitable ;
67use Illuminate \Contracts \Events \Dispatcher ;
78use Illuminate \Database \Connection ;
89use Illuminate \Database \ConnectionResolverInterface ;
1516#[AsCommand(name: 'schema:dump ' )]
1617class DumpCommand extends Command
1718{
19+ use Prohibitable;
20+
1821 /**
1922 * The console command name.
2023 *
@@ -41,6 +44,10 @@ class DumpCommand extends Command
4144 */
4245 public function handle (ConnectionResolverInterface $ connections , Dispatcher $ dispatcher )
4346 {
47+ if ($ this ->isProhibited ()) {
48+ return Command::FAILURE ;
49+ }
50+
4451 $ connection = $ connections ->connection ($ database = $ this ->input ->getOption ('database ' ));
4552
4653 $ this ->schemaState ($ connection )->dump (
You can’t perform that action at this time.
0 commit comments