|
@@ 1099-1102 (lines=4) @@
|
| 1096 |
|
|
| 1097 |
|
$cachekey = $this->ID . '_commit_' . $sha; |
| 1098 |
|
$cache = self::get_git_cache(); |
| 1099 |
|
if (!($result = $cache->load($cachekey))) { |
| 1100 |
|
$result = $repo->getCommit($sha); |
| 1101 |
|
$cache->save($result, $cachekey, ['gitonomy', 'commit', 'project_' . $this->ID]); |
| 1102 |
|
} |
| 1103 |
|
return $result; |
| 1104 |
|
} |
| 1105 |
|
|
|
@@ 1113-1116 (lines=4) @@
|
| 1110 |
|
public function getCommitMessage(\Gitonomy\Git\Commit $commit) { |
| 1111 |
|
$cachekey = $this->ID . '_message_' . $commit->getRevision(); |
| 1112 |
|
$cache = self::get_git_cache(); |
| 1113 |
|
if (!($result = $cache->load($cachekey))) { |
| 1114 |
|
$result = $commit->getMessage(); |
| 1115 |
|
$cache->save($result, $cachekey, ['gitonomy', 'message', 'project_' . $this->ID]); |
| 1116 |
|
} |
| 1117 |
|
return $result; |
| 1118 |
|
} |
| 1119 |
|
|