summaryrefslogtreecommitdiffstats
path: root/Bugzilla/BugUrl/GitHub.pm
diff options
context:
space:
mode:
Diffstat (limited to 'Bugzilla/BugUrl/GitHub.pm')
-rw-r--r--Bugzilla/BugUrl/GitHub.pm26
1 files changed, 13 insertions, 13 deletions
diff --git a/Bugzilla/BugUrl/GitHub.pm b/Bugzilla/BugUrl/GitHub.pm
index 1a0219617..a81564812 100644
--- a/Bugzilla/BugUrl/GitHub.pm
+++ b/Bugzilla/BugUrl/GitHub.pm
@@ -18,25 +18,25 @@ use base qw(Bugzilla::BugUrl);
###############################
sub should_handle {
- my ($class, $uri) = @_;
-
- # GitHub issue URLs have only one form:
- # https://github.com/USER_OR_TEAM_OR_ORGANIZATION_NAME/REPOSITORY_NAME/issues/111
- # GitHub pull request URLs have only one form:
- # https://github.com/USER_OR_TEAM_OR_ORGANIZATION_NAME/REPOSITORY_NAME/pull/111
- return (lc($uri->authority) eq 'github.com'
- and $uri->path =~ m!^/[^/]+/[^/]+/(?:issues|pull)/\d+$!) ? 1 : 0;
+ my ($class, $uri) = @_;
+
+# GitHub issue URLs have only one form:
+# https://github.com/USER_OR_TEAM_OR_ORGANIZATION_NAME/REPOSITORY_NAME/issues/111
+# GitHub pull request URLs have only one form:
+# https://github.com/USER_OR_TEAM_OR_ORGANIZATION_NAME/REPOSITORY_NAME/pull/111
+ return (lc($uri->authority) eq 'github.com'
+ and $uri->path =~ m!^/[^/]+/[^/]+/(?:issues|pull)/\d+$!) ? 1 : 0;
}
sub _check_value {
- my ($class, $uri) = @_;
+ my ($class, $uri) = @_;
- $uri = $class->SUPER::_check_value($uri);
+ $uri = $class->SUPER::_check_value($uri);
- # GitHub HTTP URLs redirect to HTTPS, so just use the HTTPS scheme.
- $uri->scheme('https');
+ # GitHub HTTP URLs redirect to HTTPS, so just use the HTTPS scheme.
+ $uri->scheme('https');
- return $uri;
+ return $uri;
}
1;