casting enabled attribute
This commit is contained in:
@@ -35,7 +35,7 @@ class DisableCommand extends Command
|
||||
return;
|
||||
}
|
||||
|
||||
if ($this->model->enabled == 0) {
|
||||
if (!$this->model->enabled) {
|
||||
$this->comment("Module [{$this->alias}] is already disabled.");
|
||||
return;
|
||||
}
|
||||
@@ -43,7 +43,7 @@ class DisableCommand extends Command
|
||||
$this->changeRuntime();
|
||||
|
||||
// Update db
|
||||
$this->model->enabled = 0;
|
||||
$this->model->enabled = false;
|
||||
$this->model->save();
|
||||
|
||||
$this->createHistory('disabled');
|
||||
|
||||
@@ -35,7 +35,7 @@ class EnableCommand extends Command
|
||||
return;
|
||||
}
|
||||
|
||||
if ($this->model->enabled == 1) {
|
||||
if ($this->model->enabled) {
|
||||
$this->comment("Module [{$this->alias}] is already enabled.");
|
||||
return;
|
||||
}
|
||||
@@ -43,7 +43,7 @@ class EnableCommand extends Command
|
||||
$this->changeRuntime();
|
||||
|
||||
// Update db
|
||||
$this->model->enabled = 1;
|
||||
$this->model->enabled = true;
|
||||
$this->model->save();
|
||||
|
||||
$this->createHistory('enabled');
|
||||
|
||||
Reference in New Issue
Block a user