Skip to content
Extraits de code Groupes Projets
Valider 837b4182 rédigé par maxwell's avatar maxwell
Parcourir les fichiers

reverting, going to write a test

parent f20078cc
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -97,9 +97,9 @@ class Person ...@@ -97,9 +97,9 @@ class Person
# Raise an error if identifier is not a valid email (generous regexp) # Raise an error if identifier is not a valid email (generous regexp)
raise "Identifier is invalid" if !(identifier =~ /\A.*\@.*\..*\Z/) raise "Identifier is invalid" if !(identifier =~ /\A.*\@.*\..*\Z/)
query = identifier.gsub('acct:', '').to_s query = /#{Regexp.escape(identifier.gsub('acct:', '').to_s)}/i
local_person = Person.find_by_diaspora_handle(:diaspora_handle => query) local_person = Person.first(:diaspora_handle => query)
if local_person if local_person
Rails.logger.info("Do not need to webfinger, found a local person #{local_person.real_name}") Rails.logger.info("Do not need to webfinger, found a local person #{local_person.real_name}")
local_person local_person
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter