diff --git a/LibHooks/lib/PreCommit/Filter/ShortCommitMsg/GitHub/Parser.php b/LibHooks/lib/PreCommit/Filter/ShortCommitMsg/GitHub/Parser.php index c2f193f..f135296 100644 --- a/LibHooks/lib/PreCommit/Filter/ShortCommitMsg/GitHub/Parser.php +++ b/LibHooks/lib/PreCommit/Filter/ShortCommitMsg/GitHub/Parser.php @@ -13,4 +13,17 @@ class Parser extends ShortCommitMsg\Jira\Parser implements InterpreterInterface { + /** + * Convert issue number to issue key + * + * Add project key to issue number when it did not set. + * + * @param string $issueNo + * @return string + * @throws \PreCommit\Exception + */ + protected function _normalizeIssueKey($issueNo) + { + return "#" . ltrim($issueNo, '#'); + } }