Created
April 28, 2015 05:22
-
-
Save theRealNG/ab4652bda1109517fa6f to your computer and use it in GitHub Desktop.
Over ridding devise current_user to use for the API authentication
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def current_user | |
@current_user ||= User.find_by(auth_token: request.headers["Authorization"]) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment