From 298c0ef1bfd6b1e156ed71fd32d5fdd5c610336c Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Tue, 15 Jan 2019 18:32:24 +0800 Subject: [PATCH] Fix #5661 - MTrack - daily email large and no branch --- MTrack/SCM/Git/CommitHookBridge.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MTrack/SCM/Git/CommitHookBridge.php b/MTrack/SCM/Git/CommitHookBridge.php index 2c5dee21..328c93b8 100644 --- a/MTrack/SCM/Git/CommitHookBridge.php +++ b/MTrack/SCM/Git/CommitHookBridge.php @@ -26,7 +26,7 @@ class MTrack_SCM_Git_CommitHookBridge extends IMTrackCommitHookBridge while (($line = fgets(STDIN)) !== false) { echo "got: $line\n"; list($old, $new, $ref) = explode(' ', trim($line), 3); - $this->branch = $ref; + $this->branch = preg_replace('#^refs/heads/#','', $ref); $this->commits[] = $new; if (preg_match('/^0+$/',$old)) { -- 2.39.2