Merge pull request #1935 from mattr-/simplify-login-system

Simplify the return values when using basic auth
This commit is contained in:
Dan Rice 2015-11-03 00:15:43 -05:00
commit da7a97b9b5

View file

@ -195,15 +195,12 @@ module LoginSystem
end
if authdata and authdata[0] == 'Basic'
data = Base64.decode64(authdata[1]).split(':')[0..1]
return {
{
user: data[0],
pass: data[1]
}
else
return {
user: ''.freeze,
pass: ''.freeze
}
{}
end
end