Skip to content
This repository has been archived by the owner on Aug 28, 2023. It is now read-only.

Commit

Permalink
Gracefully handle no projects available
Browse files Browse the repository at this point in the history
  • Loading branch information
dcramer committed Feb 29, 2016
1 parent b056144 commit 4f8c116
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion sentry_jira/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,10 @@ def __init__(self, data=None, *args, **kwargs):
has_credentials = False
can_auto_create = False
else:
self.fields["default_issue_type"].choices = JIRAFormUtils.make_choices(meta["issuetypes"])
if meta:
self.fields["default_issue_type"].choices = JIRAFormUtils.make_choices(meta["issuetypes"])
else:
can_auto_create = False

if not has_credentials:
self.fields['password'].required = True
Expand Down

0 comments on commit 4f8c116

Please sign in to comment.