-1

I have tried everithing starting following this guide

https://adibsaad.com/blog/setting-up-ember-cli-with-a-rails-back-end-and-token-authentication-authorization

but still it does not work. When I try to reach pages that are protected with authentication token the server give me "unauthorized 401". Here

https://github.com/francescabarbazeni87/Ember-Devise-Simple-Auth-Example-

there is my code for the server and client side. Many thanks in advance.

Francesca
  • 138
  • 7
  • Can you please paste your HTTP request from console – Rigel Sep 06 '15 at 17:35
  • Please consider adding [minimal example](http://stackoverflow.com/help/mcve) to your question, instead of linking to external site. See ["How do I ask good question"](http://stackoverflow.com/help/how-to-ask):help others reproduce the problem section. – XLII Sep 07 '15 at 05:28

1 Answers1

0
class ApplicationController < ActionController::Base
  before_filter :authenticate_user_from_token!

  # Enter the normal Devise authentication path,
  # using the token authenticated user if available
  #before_filter :authenticate_user! <-----you dont need this line...delete or comment it out
Rigel
  • 882
  • 1
  • 11
  • 32