An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.
PHP coolifydatabasesdeploymentdockerdocker-composeinertiajslaravelmariadbmysqlnextjsnodejsphppostgresredisself-hostedself-hostingserverstatic-sitesveltesvelte5
fix: migration
Andras Bacsaib2000f2950e6
diff --git a/database/migrations/2024_11_11_125366_add_index_to_activity_log.php b/database/migrations/2024_11_11_125366_add_index_to_activity_log.phpindex 9565187d03..0c281ff402 100644--- a/database/migrations/2024_11_11_125366_add_index_to_activity_log.php+++ b/database/migrations/2024_11_11_125366_add_index_to_activity_log.php@@ -2,19 +2,27 @@use Illuminate\Database\Migrations\Migration;use Illuminate\Support\Facades\DB;+use Illuminate\Support\Facades\Log;class AddIndexToActivityLog extends Migration{public function up(){- DB::statement('ALTER TABLE activity_log ALTER COLUMN properties TYPE jsonb USING properties::jsonb');- DB::statement('CREATE INDEX idx_activity_type_uuid ON activity_log USING GIN (properties jsonb_path_ops)');+ try {+ DB::statement('ALTER TABLE activity_log ALTER COLUMN properties TYPE jsonb USING properties::jsonb');+ DB::statement('CREATE INDEX idx_activity_type_uuid ON activity_log USING GIN (properties jsonb_path_ops)');+ } catch (\Exception $e) {+ Log::error('Error adding index to activity_log: '.$e->getMessage());+ }}public function down(){- DB::statement('DROP INDEX IF EXISTS idx_activity_type_uuid');- DB::statement('ALTER TABLE activity_log ALTER COLUMN properties TYPE json USING properties::json');-+ try {+ DB::statement('DROP INDEX IF EXISTS idx_activity_type_uuid');+ DB::statement('ALTER TABLE activity_log ALTER COLUMN properties TYPE json USING properties::json');+ } catch (\Exception $e) {+ Log::error('Error dropping index from activity_log: '.$e->getMessage());+ }}}