|
@@ 1147-1150 (lines=4) @@
|
| 1144 |
|
|
| 1145 |
|
$cachekey = $this->ID.'_commit_'.$sha; |
| 1146 |
|
$cache = self::get_git_cache(); |
| 1147 |
|
if (!($result = $cache->load($cachekey))) { |
| 1148 |
|
$result = $repo->getCommit($sha); |
| 1149 |
|
$cache->save($result, $cachekey, ['gitonomy', 'commit', 'project_'.$this->ID]); |
| 1150 |
|
} |
| 1151 |
|
return $result; |
| 1152 |
|
} |
| 1153 |
|
|
|
@@ 1161-1164 (lines=4) @@
|
| 1158 |
|
public function getCommitMessage(\Gitonomy\Git\Commit $commit) { |
| 1159 |
|
$cachekey = $this->ID.'_message_'.$commit->getRevision(); |
| 1160 |
|
$cache = self::get_git_cache(); |
| 1161 |
|
if (!($result = $cache->load($cachekey))) { |
| 1162 |
|
$result = $commit->getMessage(); |
| 1163 |
|
$cache->save($result, $cachekey, ['gitonomy', 'message', 'project_'.$this->ID]); |
| 1164 |
|
} |
| 1165 |
|
return $result; |
| 1166 |
|
} |
| 1167 |
|
|