add db migration to remove asset paths from metacodes
This commit is contained in:
parent
da98a53a3e
commit
9de4492f04
1 changed files with 8 additions and 0 deletions
|
@ -0,0 +1,8 @@
|
||||||
|
class RemoveAssetPathsFromMetacodes < ActiveRecord::Migration
|
||||||
|
def change
|
||||||
|
Metacode.all.each do |metacode|
|
||||||
|
metacode.icon = metacode.icon.gsub(/^\/assets\//, '')
|
||||||
|
metacode.save
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
Loading…
Reference in a new issue