Skip to content

Commit

Permalink
fix(migration): Add log warning for fulltextsearch
Browse files Browse the repository at this point in the history
  • Loading branch information
gnovaro committed Mar 9, 2024
1 parent 78eb76c commit 4000f67
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 21 deletions.
Original file line number Diff line number Diff line change
@@ -1,19 +1,12 @@
<?php

use Illuminate\Console\Command;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\Facades\Log;

return new class extends Migration
{
protected Command $command;

public function __construct(Command $command)
{
$this->command = $command;
}

/**
* Run the migrations.
*
Expand All @@ -31,7 +24,7 @@ public function up()
});
} else {
// Output a warning indicating that the database driver does not support fulltext index creation
$this->command->info('Warning: Fulltext index creation is not supported by this database driver.');
Log::warning('Warning: Fulltext index creation is not supported by this database driver.');
}
}

Expand All @@ -52,7 +45,7 @@ public function down()
});
} else {
// Output a warning indicating that the database driver does not support fulltext index creation
$this->command->info('Warning: Fulltext index creation is not supported by this database driver.');
Log::warning('Warning: Fulltext index creation is not supported by this database driver.');
}
}
};
Original file line number Diff line number Diff line change
@@ -1,19 +1,12 @@
<?php

use Illuminate\Console\Command;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\Facades\Log;

return new class extends Migration
{
protected Command $command;

public function __construct(Command $command)
{
$this->command = $command;
}

/**
* Run the migrations.
*
Expand All @@ -31,7 +24,7 @@ public function up()
});
} else {
// Output a warning indicating that the database driver does not support fulltext index creation
$this->command->info('Warning: Fulltext index creation is not supported by this database driver.');
Log::warning('Warning: Fulltext index creation is not supported by this database driver.');
}
}

Expand All @@ -52,7 +45,7 @@ public function down()
});
} else {
// Output a warning indicating that the database driver does not support fulltext index creation
$this->command->info('Warning: Fulltext index creation is not supported by this database driver.');
Log::warning('Warning: Fulltext index creation is not supported by this database driver.');
}
}
};
2 changes: 1 addition & 1 deletion version.php
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<?php

const APP_VERSION = '3.7.9';
const APP_VERSION = '3.7.10';

0 comments on commit 4000f67

Please sign in to comment.