# When toggling a mute between hiding and allowing notifications, the mute will already exist, so the find_or_create_by! call will return the existing Mute without updating the hide_notifications attribute. Therefore, we check that hide_notifications? is what we want and set it if it isn't.
# When toggling a mute between hiding and allowing notifications, the mute will already exist, so the find_or_create_by! call will return the existing Mute without updating the hide_notifications attribute. Therefore, we check that hide_notifications? is what we want and set it if it isn't.
raiseWebfinger::RedirectError,"Too many webfinger redirects for URI #{@uri} (stopped at #{@username}@#{@domain})"unlessconfirmed_username.casecmp(@username).zero?&&confirmed_domain.casecmp(@domain).zero?
raiseWebfinger::RedirectError,"Too many webfinger redirects for URI #{@uri} (stopped at #{@username}@#{@domain})"
end
raiseError,"Webfinger response for #{@username}@#{@domain} does not loop back to #{@uri}"ifwebfinger.link('self','href')!=@uri
raiseError,"Webfinger response for #{@username}@#{@domain} does not loop back to #{@uri}"ifwebfinger.link('self','href')!=@uri
raiseWebfinger::RedirectError,"Too many webfinger redirects for URI #{uri} (stopped at #{@username}@#{@domain})"unlessconfirmed_username.casecmp(@username).zero?&&confirmed_domain.casecmp(@domain).zero?
raiseWebfinger::RedirectError,"Too many webfinger redirects for URI #{uri} (stopped at #{@username}@#{@domain})"