mirror of
https://github.com/Dvorinka/MyClubServer.git
synced 2026-06-04 02:32:57 +00:00
upload
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
-- +goose Down
|
||||
-- SQL in this section is executed when the migration is rolled back
|
||||
|
||||
-- Drop tables
|
||||
DROP TABLE IF EXISTS social_links;
|
||||
DROP TABLE IF EXISTS navigation_items;
|
||||
|
||||
-- Remove settings columns
|
||||
DO $$
|
||||
BEGIN
|
||||
IF EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'settings') THEN
|
||||
IF EXISTS (SELECT 1 FROM information_schema.columns
|
||||
WHERE table_name = 'settings' AND column_name = 'custom_navigation_enabled') THEN
|
||||
ALTER TABLE settings DROP COLUMN custom_navigation_enabled;
|
||||
END IF;
|
||||
|
||||
IF EXISTS (SELECT 1 FROM information_schema.columns
|
||||
WHERE table_name = 'settings' AND column_name = 'show_social_in_nav') THEN
|
||||
ALTER TABLE settings DROP COLUMN show_social_in_nav;
|
||||
END IF;
|
||||
END IF;
|
||||
END $$;
|
||||
Reference in New Issue
Block a user