Always destroy id current list (please find good design pattern you fuck 😠)
This commit is contained in:
@@ -62,5 +62,7 @@ App.ApplicationController = Ember.Controller.extend
|
||||
# if jqXHR.status == 404 officially, now assume close list on error
|
||||
#@redirect_to 'index', message: 'the_list_has_been_closed'
|
||||
console.log "Error: #{emberError.message}" if emberError.message
|
||||
if error_list = @store.all('list').findBy('id', 'current')
|
||||
error_list.eraseRecord()
|
||||
@set 'list', null
|
||||
@store.find('list', 'current').then(success, error)
|
||||
|
||||
Reference in New Issue
Block a user