mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-15 04:11:41 +00:00
tarde para este typo... #84
This commit is contained in:
parent
8f38f2fe5f
commit
305921ae63
1 changed files with 1 additions and 1 deletions
|
@ -3,6 +3,6 @@ class ChangeRefererToOrigin < ActiveRecord::Migration[6.0]
|
|||
rename_column :access_logs, :http_referer, :http_origin
|
||||
|
||||
# Eliminar todos los referers anteriores manteniendo el origin
|
||||
ActiveRecord::Base.connection.execute("update access_logs set http_origin = split_part(http_origin, '/', 1) || '//' || split_part(http_origin, '/', 2) where http_origin is not null")
|
||||
ActiveRecord::Base.connection.execute("update access_logs set http_origin = split_part(http_origin, '/', 1) || '//' || split_part(http_origin, '/', 3) where http_origin is not null")
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue