Skip to content

Commit

Permalink
Make dependents optional
Browse files Browse the repository at this point in the history
  • Loading branch information
achembarpu committed Aug 3, 2018
1 parent aad4ae1 commit 3413fb3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fixture_magic/management/commands/custom_dump.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def handle(self, *args, **options):
include_primary = dump_settings.get("include_primary", False)
dump_me = loading.get_model(app_label, model_name)
objs = dump_me.objects.filter(pk__in=[int(i) for i in pks])
deps = dump_settings['dependents']
deps = dump_settings.get('dependents', [])
for obj in objs.all():
# get the dependent objects and add to serialize list
for dep in deps:
Expand Down

0 comments on commit 3413fb3

Please sign in to comment.