mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-06-26 06:52:13 +02:00
Try again to fix travis...
This commit is contained in:
parent
9751f9f648
commit
8590f55546
@ -18,15 +18,25 @@ class SplitTwofaccountsUriInMultipleColumns extends Migration
|
|||||||
{
|
{
|
||||||
$driver = Schema::connection($this->getConnection())->getConnection()->getDriverName();
|
$driver = Schema::connection($this->getConnection())->getConnection()->getDriverName();
|
||||||
|
|
||||||
|
// as SQLITE disallow to add a not nullable column without default
|
||||||
|
// value when altering a table we add all columns as nullable and
|
||||||
|
// change them right after to not nullable column
|
||||||
Schema::table('twofaccounts', function (Blueprint $table) {
|
Schema::table('twofaccounts', function (Blueprint $table) {
|
||||||
$table->string('otp_type', 10);
|
$table->string('otp_type', 10)->nullable();
|
||||||
$table->text('secret');
|
$table->text('secret')->nullable();
|
||||||
$table->string('algorithm', 20);
|
$table->string('algorithm', 20)->nullable();
|
||||||
$table->unsignedTinyInteger('digits');
|
$table->unsignedSmallInteger('digits')->nullable();
|
||||||
$table->unsignedInteger('period')->nullable();
|
$table->unsignedInteger('period')->nullable();
|
||||||
$table->unsignedBigInteger('counter')->nullable();
|
$table->unsignedBigInteger('counter')->nullable();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Schema::table('twofaccounts', function (Blueprint $table){
|
||||||
|
$table->string('otp_type', 10)->nullable(false)->change();
|
||||||
|
$table->text('secret')->nullable(false)->change();
|
||||||
|
$table->string('algorithm', 20)->nullable(false)->change();
|
||||||
|
$table->unsignedSmallInteger('digits')->nullable(false)->change();
|
||||||
|
});
|
||||||
|
|
||||||
// Apply previous migration 'AlterEncryptedColumnsToText' even to sqlite base
|
// Apply previous migration 'AlterEncryptedColumnsToText' even to sqlite base
|
||||||
if ('sqlite' === $driver) {
|
if ('sqlite' === $driver) {
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user