This website works better with JavaScript.
Home
Explore
Help
Sign In
closed-social
/
mastodon
Watch
3
Star
0
Fork
2
Code
Issues
5
Pull Requests
0
Projects
0
Releases
3
Wiki
Activity
Browse Source
Apply Rubocop Performance/StringReplacement (
#23445
)
closed-social-glitch-2
Nick Schonning
1 year ago
committed by
GitHub
parent
203739dd3a
commit
d3f59f52c3
No known key found for this signature in database
GPG Key ID:
4AEE18F83AFDEB23
1 changed files
with
1 additions
and
1 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+1
-1
app/helpers/email_helper.rb
+ 1
- 1
app/helpers/email_helper.rb
View File
@ -7,7 +7,7 @@ module EmailHelper
def
email_to_canonical_email
(
str
)
username
,
domain
=
str
.
downcase
.
split
(
'@'
,
2
)
username
,
=
username
.
gsub
(
'.
'
,
'
'
)
.
split
(
'+'
,
2
)
username
,
=
username
.
delete
(
'.'
)
.
split
(
'+'
,
2
)
"
#{
username
}
@
#{
domain
}
"
end
Write
Preview
Loading…
Cancel
Save