Skip to content

Commit be32f58

Browse files
DEV: Delete unused site settings (#23353)
In a previous commit these site settings were removed from the codebase because they were identified as unused settings. This commit removes these settings from the db in case they existed in the site settings table. Follow up to: da389d7
1 parent 72f33d1 commit be32f58

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# frozen_string_literal: true
2+
3+
class DeleteUnusedSiteSettings < ActiveRecord::Migration[7.0]
4+
def up
5+
execute <<~SQL
6+
DELETE
7+
FROM
8+
"site_settings"
9+
WHERE
10+
"name" IN (
11+
'rate_limit_new_user_create_topic',
12+
'enable_system_avatars',
13+
'check_for_new_features',
14+
'allow_user_api_keys'
15+
)
16+
SQL
17+
end
18+
19+
def down
20+
raise ActiveRecord::IrreversibleMigration
21+
end
22+
end

0 commit comments

Comments
 (0)