Skip to content

Instantly share code, notes, and snippets.

@bholzer
Created January 4, 2018 04:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bholzer/a2100639c7fc5de70a318e4de4e8761b to your computer and use it in GitHub Desktop.
Save bholzer/a2100639c7fc5de70a318e4de4e8761b to your computer and use it in GitHub Desktop.
def response_for_auth_fail(auth_error: :invalid)
messages = {
invalid: "Some error",
inactive: "Some error"
locked: "Some error"
}
{ auth_error: auth_error, message: messages[:auth_error] }
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment