corrected incorrect regex
This commit is contained in:
parent
0064740c13
commit
ac79db5f66
2 changed files with 2 additions and 6 deletions
|
@ -1,4 +0,0 @@
|
|||
RewriteEngine on
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteRule ^(.*)$ /index.php?path=$1 [NC,L,QSA]
|
|
@ -85,13 +85,13 @@ func parseUsername(svc Service) string {
|
|||
if svc.UsernameIsFQDN && !svc.RequireLocalDomain{
|
||||
return email
|
||||
} else if svc.UsernameIsFQDN && svc.RequireLocalDomain {
|
||||
re := regexp.MustCompile(`[^@]+$`)
|
||||
re := regexp.MustCompile(`[^@(%40)]+$`)
|
||||
domain := re.FindString(email)
|
||||
localemail := strings.Replace(email, domain,
|
||||
global.MainConfig.LocalDomain,1)
|
||||
return localemail
|
||||
} else {
|
||||
re := regexp.MustCompile(`^[^@]+`)
|
||||
re := regexp.MustCompile(`^[^@(%40)]+`)
|
||||
username := re.FindString(email)
|
||||
return username
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue