7 Commits

Author SHA1 Message Date
James Lu
4dd3f7ff08 GitLab: fix searching for X-Gitlab-Event
This was broken by 726ac377ed29363c9a88fc1ef51523718e3540b7
2019-12-24 13:19:29 -08:00
James Lu
726ac377ed GitLab: s/Gitlab/GitLab/g 2019-11-08 19:04:19 -08:00
James Lu
6382b9d197 GitLab: Store super() information so that reloads don't fail with TypeError
This happens because the named reference to the "Gitlab" class is replaced by a new version on reload, making the old instance no longer an instance of it.

(cherry picked from commit f5ffcee53f)
2019-11-08 19:02:58 -08:00
James Lu
83fdfeb113 GitLab: Add an option to use NOTICE instead of PRIVMSG
(cherry picked from commit 3c0d66ea34)
2019-11-08 19:02:31 -08:00
James Lu
caed6ec0a5 GitLab: Drop the need for channel names in the URL
This behaviour was unclear and misleading for a number of reasons:
- The channel name was actually only used for checking the bot's channel presence, and not as the announcement target.
- What the plugin actually did is check *all* channels the bot is in on the target network for configured announcements,
  and announce to all of them (regardless of what channel was given in the URL).

Backwards compatibility with the old URL format is kept with this commit.

(cherry picked from commit 630786e541)
2019-11-08 19:02:06 -08:00
James Lu
46719240b0 GitLab: Fix support for multiple networks
Instead of fixing the webhook handler to the network where the plugin was loaded, dynamically search through networks (much like the plugin already did with channels).

This also makes the plguin raise an explicit error if a network+channel target is unknown, instead of leaving any frontend servers with confusing 502 (Bad Gateway) errors.

(cherry picked from commit 140d724fb3)
2019-11-08 19:00:53 -08:00
Moritz Lipp
175b3b7612 Import https://github.com/mlq/limnoria-gitlab@a58314f 2019-11-08 18:56:48 -08:00