Fixes new setup migration for auto-increment

This commit is contained in:
snipe 2017-06-20 12:23:32 -07:00
parent 5b9bcd8fa2
commit 274f3511f5

View file

@ -26,9 +26,12 @@ class AddNextAutoincrementToSettings extends Migration
});
\Log::debug('Setting '.$next.' as default auto-increment');
$settings = App\Models\Setting::first();
$settings->next_auto_tag_base = $next;
$settings->save();
if ($settings = App\Models\Setting::first()) {
$settings->next_auto_tag_base = $next;
$settings->save();
}
}