ember-auth icon indicating copy to clipboard operation
ember-auth copied to clipboard

then and fail callbacks are not executed after authenticating

Open DVG opened this issue 10 years ago • 0 comments

I have an example app: https://github.com/DVG/boards

When I successfully sign in, I am trying to hide the spinner on the page using the .then callback as outlined in the docs

Boards.LoginController = Ember.Controller.extend
  email: null
  password: null

  actions:
    login: () ->
      $(".spinner").show()
      @auth.signIn
        data:
          email: @get 'email'
          password: @get 'password'
      .then ->
        $(".spinner").hide()

The code in the then never gets executed, even though the server is returning a 200 status with an auth-token as expected.

DVG avatar Aug 29 '14 02:08 DVG