Skip to content

Commit

Permalink
fix django 1.10 issue: Access _default_manager on the model instance'…
Browse files Browse the repository at this point in the history
…s type, not the instance (#432)
  • Loading branch information
mfenniak authored and auvipy committed Jun 29, 2016
1 parent ec52037 commit 803234d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion djcelery/schedulers.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def __next__(self):
def save(self):
# Object may not be synchronized, so only
# change the fields we care about.
obj = self.model._default_manager.get(pk=self.model.pk)
obj = type(self.model)._default_manager.get(pk=self.model.pk)
for field in self.save_fields:
setattr(obj, field, getattr(self.model, field))
obj.last_run_at = make_aware(obj.last_run_at)
Expand Down

1 comment on commit 803234d

@idesignedme
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how do I add this to my heroku app?

Please sign in to comment.