Skip to content

Commit 1739ad3

Browse files
committed
add zeitwerk instance config migration
1 parent 9e61b53 commit 1739ad3

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
class AdaptZeitwerkSkosNamingToInstanceConfiguration < ActiveRecord::Migration[7.1]
2+
def up
3+
execute "UPDATE configuration_settings SET key = REGEXP_REPLACE(key, '::SKOS::', '::Skos::', 'g') WHERE key LIKE '%::SKOS::%';"
4+
execute "UPDATE configuration_settings SET key = REGEXP_REPLACE(key, '::SKOSXL::', '::Skosxl::', 'g') WHERE key LIKE '%::SKOSXL::%';"
5+
end
6+
7+
def down
8+
execute "UPDATE configuration_settings SET key = REGEXP_REPLACE(key, '::Skos::', '::SKOS::', 'g') WHERE key LIKE '%::Skos::%';"
9+
execute "UPDATE configuration_settings SET key = REGEXP_REPLACE(key, '::Skosxl::', '::SKOSXL::', 'g') WHERE key LIKE '%::Skosxl::%';"
10+
end
11+
end

0 commit comments

Comments
 (0)