getoutreach / epf

A framework for keeping your Ember.js apps in sync.
http://epf.io
MIT License
369 stars 33 forks source link

session.flush() does randomly trigger POST #72

Closed sebzincktiz closed 10 years ago

sebzincktiz commented 11 years ago

Problem: The call to session.flush() does randomly trigger POST

Source:

var self = this,
newUser = self.session.create(App.User,{name:'Seb'}); 

self.session.flush().then(function() { 
    self.get("content").addObject(newUser);
}, function(exception){
    console.error(exception);  
});

User definition:

App.User = Ep.Model.extend({
    name: Ep.attr('string')    
});
jasonkriss commented 11 years ago

What exactly do you mean by "session.flush() does randomly trigger POST"? This code should trigger a post to /users. Are you saying it does not?

sebzincktiz commented 11 years ago

I mean that sometimes this piece of code trigger a POST request sometimes no. I can't figure out why...

ghempton commented 10 years ago

@sebzincktiz can you elaborate on this situation?

ghempton commented 10 years ago

Going to close until we can get more information