From: Matt Selsky Date: Fri, 24 Oct 2014 08:22:20 +0000 (+0100) Subject: Bug 1088399 - Add support for Github pull requests in See Also field. r=gerv, a=glob. X-Git-Tag: release-5.1.1~483 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1d68680f1a510aa5fd7844dca3f8a681db334761;p=thirdparty%2Fbugzilla.git Bug 1088399 - Add support for Github pull requests in See Also field. r=gerv, a=glob. --- diff --git a/Bugzilla/BugUrl/GitHub.pm b/Bugzilla/BugUrl/GitHub.pm index 22814dc50e..f14f1d6b05 100644 --- a/Bugzilla/BugUrl/GitHub.pm +++ b/Bugzilla/BugUrl/GitHub.pm @@ -22,8 +22,10 @@ sub should_handle { # 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/\d+$|) ? 1 : 0; + and $uri->path =~ m!^/[^/]+/[^/]+/(?:issues|pull)/\d+$!) ? 1 : 0; } sub _check_value { diff --git a/template/en/default/global/user-error.html.tmpl b/template/en/default/global/user-error.html.tmpl index ed07487608..81bfe7f30a 100644 --- a/template/en/default/global/user-error.html.tmpl +++ b/template/en/default/global/user-error.html.tmpl @@ -290,7 +290,7 @@
  • A ticket in a Trac installation.
  • A b[% %]ug in a MantisBT installation.
  • A b[% %]ug on sourceforge.net.
  • -
  • An issue on github.com.
  • +
  • An issue/pull request on github.com.
  • [% Hook.process('bug_url_invalid_tracker') %] [% END %]