Skip to content

Commit

Permalink
flake 8 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
David-Esteves committed Aug 9, 2018
1 parent 4eb1fe7 commit 44b6785
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions arctic/generics.py
Expand Up @@ -447,8 +447,10 @@ def get_list_items(self, objects): # noqa: C901
if len(embeded_list) > self.max_embeded_list_items:
embeded_list = embeded_list[:-1] + ['...']
field['value'] = embeded_list
# don't try to find url for value that is None for related objects.
if field_name in field_links.keys() and field['value'] is not None:
# don't try to find url for value that
# is None for related objects.
if (field_name in field_links.keys() and
field['value'] is not None):
field['url'] = self.in_modal(reverse_url(
field_links[field_name], obj, self.primary_key))
field['modal'] = self.get_modal_link(
Expand Down

0 comments on commit 44b6785

Please sign in to comment.