DNProject::getCommitTags PHP Method

getCommitTags() public method

public getCommitTags ( Gitonomy\Git\Commit $commit ) : mixed
$commit Gitonomy\Git\Commit
return mixed
    public function getCommitTags(\Gitonomy\Git\Commit $commit)
    {
        $cachekey = $this->ID . '_tags_' . $commit->getRevision();
        $cache = self::get_git_cache();
        $result = $cache->load($cachekey);
        // we check against false, because in many cases the tag list is an empty array
        if ($result === false) {
            $repo = $this->getRepository();
            $result = $repo->getReferences()->resolveTags($commit->getRevision());
            $cache->save($result, $cachekey, ['gitonomy', 'tags', 'project_' . $this->ID]);
        }
        return $result;
    }