aliases: fix bug when trying to move wiki pages.

This commit is contained in:
evazion
2019-12-26 15:13:14 -06:00
parent 231e4872ed
commit b6a3a05422
2 changed files with 11 additions and 1 deletions

View File

@@ -150,7 +150,7 @@ class TagAlias < TagRelationship
antecedent_wiki = WikiPage.titled(antecedent_name).first
if antecedent_wiki.present?
if WikiPage.titled(consequent_name).blank?
antecedent_wiki.update!(title: consequent_name, skip_secondary_validations: true)
antecedent_wiki.update!(title: consequent_name)
else
forum_updater.update(conflict_message)
end