Do not show “getting started” screen if session check failed.
This commit is contained in:
parent
a0caaa06e9
commit
212077d81d
2 changed files with 6 additions and 2 deletions
|
@ -21,7 +21,7 @@ class App.Auth
|
||||||
params.error(xhr, statusText, error)
|
params.error(xhr, statusText, error)
|
||||||
)
|
)
|
||||||
|
|
||||||
@loginCheck: ->
|
@loginCheck: (callback) ->
|
||||||
params =
|
params =
|
||||||
fingerprint: App.Browser.fingerprint()
|
fingerprint: App.Browser.fingerprint()
|
||||||
App.Log.debug 'Auth', 'loginCheck'
|
App.Log.debug 'Auth', 'loginCheck'
|
||||||
|
@ -36,6 +36,9 @@ class App.Auth
|
||||||
# set login (config, session, ...)
|
# set login (config, session, ...)
|
||||||
@_login(data, 'check')
|
@_login(data, 'check')
|
||||||
|
|
||||||
|
if callback
|
||||||
|
callback()
|
||||||
|
|
||||||
error: (xhr, statusText, error) =>
|
error: (xhr, statusText, error) =>
|
||||||
@_loginError()
|
@_loginError()
|
||||||
)
|
)
|
||||||
|
|
|
@ -15,8 +15,9 @@ class App.Run extends App.Controller
|
||||||
App.Collection.init()
|
App.Collection.init()
|
||||||
|
|
||||||
# check if session already exists/try to get session data from server
|
# check if session already exists/try to get session data from server
|
||||||
App.Auth.loginCheck()
|
App.Auth.loginCheck(@start)
|
||||||
|
|
||||||
|
start: =>
|
||||||
# create web socket connection
|
# create web socket connection
|
||||||
App.WebSocket.connect()
|
App.WebSocket.connect()
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue