Skip to content

Commit

Permalink
Fixed typos (#60)
Browse files Browse the repository at this point in the history
  • Loading branch information
jackton1 authored and c17r committed Jan 26, 2020
1 parent 10168a3 commit 9bac046
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion service_objects/celery_services.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def _deflate_model(value):
Transforms model instances into picklable tuple.
"""
if isinstance(value, models.Model):
return (value.__class__, value.pk)
return value.__class__, value.pk
return value

@staticmethod
Expand Down
6 changes: 3 additions & 3 deletions tests/test_celery_services.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ def test_cleaned_data_pickling(self):
service.is_valid()

# Check deflated ModelField format
defalted_models = self.initial_data.copy()
defalted_models["foo"] = (CustomFooModel, self.foo.pk)
deflated_models = self.initial_data.copy()
deflated_models["foo"] = (CustomFooModel, self.foo.pk)

self.assertEqual(
CeleryService._deflate_models(service.cleaned_data), defalted_models
CeleryService._deflate_models(service.cleaned_data), deflated_models
)

# Check deflate/inflate invariant
Expand Down

0 comments on commit 9bac046

Please sign in to comment.