aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorGravatar jesopo2019-05-17 10:14:49 +0100
committerGravatar jesopo2019-05-17 10:14:49 +0100
commitf3d9fbb21668d9f02ebab985ff91601324c38656 (patch)
treeafd9f23095c170565932707019fc546d34d40323 /modules
parentUse github-default-repo to fill in org when org is missing but repo isn't (diff)
signature
Actually assume the provided "org" is the repo when repo isn't provided
Diffstat (limited to 'modules')
-rw-r--r--modules/github/__init__.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/modules/github/__init__.py b/modules/github/__init__.py
index a492afa9..9c0a3f82 100644
--- a/modules/github/__init__.py
+++ b/modules/github/__init__.py
@@ -115,8 +115,12 @@ class Module(ModuleManager.BaseModule):
default_repo = channel.get_setting("github-default-repo", "")
default_org, _, default_repo = default_repo.partition("/")
- org = org or default_org
- repo = repo or default_repo
+ if org and not repo:
+ org = default_org
+ repo = org or default_repo
+ else:
+ org = org or default_org
+ repo = repo or default_repo
if not org or not repo or not number:
raise utils.EventError("Please provide username/repo#number")