match .lower() repo names against .lower() hooked repo names
This commit is contained in:
parent
195cb66e26
commit
bd5bc81d1c
1 changed files with 7 additions and 6 deletions
|
@ -65,13 +65,14 @@ class Module(ModuleManager.BaseModule):
|
||||||
repo_hooked = False
|
repo_hooked = False
|
||||||
|
|
||||||
for server_id, channel_name, hooked_repos in hooks:
|
for server_id, channel_name, hooked_repos in hooks:
|
||||||
|
hooked_repos_lower = {k.lower(): v for k, v in hooked_repos.items()}
|
||||||
found_hook = None
|
found_hook = None
|
||||||
if full_name_lower and full_name_lower in hooked_repos:
|
if full_name_lower and full_name_lower in hooked_repos_lower:
|
||||||
found_hook = hooked_repos[full_name_lower]
|
found_hook = hooked_repos_lower[full_name_lower]
|
||||||
elif repo_username_lower and repo_username_lower in hooked_repos:
|
elif repo_username_lower and repo_username_lower in hooked_repos_lower:
|
||||||
found_hook = hooked_repos[repo_username_lower]
|
found_hook = hooked_repos_lower[repo_username_lower]
|
||||||
elif organisation_lower and organisation_lower in hooked_repos:
|
elif organisation_lower and organisation_lower in hooked_repos_lower:
|
||||||
found_hook = hooked_repos[organisation_lower]
|
found_hook = hooked_repos_lowers[organisation_lower]
|
||||||
else:
|
else:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue