mirror of
https://github.com/pelican-dev/panel.git
synced 2026-05-04 18:00:48 +03:00
Collection of smaller v4 fixes (#1684)
Co-authored-by: RMartinOscar <40749467+RMartinOscar@users.noreply.github.com> Co-authored-by: notCharles <charles@pelican.dev>
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
<?php
|
||||
|
||||
use App\Models\User;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
@@ -18,16 +17,6 @@ return new class extends Migration
|
||||
$table->boolean('mfa_email_enabled')->default(false);
|
||||
});
|
||||
|
||||
User::chunk(100, function ($users) {
|
||||
foreach ($users as $user) {
|
||||
$user->update([
|
||||
'mfa_app_secret' => $user->use_totp ? $user->totp_secret : null,
|
||||
'mfa_app_recovery_codes' => null,
|
||||
'mfa_email_enabled' => false,
|
||||
]);
|
||||
}
|
||||
});
|
||||
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->dropColumn('use_totp');
|
||||
$table->dropColumn('totp_secret');
|
||||
|
||||
Reference in New Issue
Block a user