summaryrefslogtreecommitdiff
path: root/qa
diff options
context:
space:
mode:
authorNick Thomas <nick@gitlab.com>2018-10-12 14:42:35 +0100
committerNick Thomas <nick@gitlab.com>2018-10-17 16:24:36 +0100
commit0669127a328af171850afb01deef2a07eb89a6a6 (patch)
tree8a25b2e738eb131f89b21ce1cb93442ae89b6299 /qa
parente347170cc59dfa1e48de451f7c48ccb65d3e581a (diff)
downloadgitlab-ce-0669127a328af171850afb01deef2a07eb89a6a6.tar.gz
Use cached readme blobs where appropriate
GitLab keeps a cache of the rendered HTML for a repository's README as stored in the HEAD branch. However, it was not used in all circumstances. In particular, the new blob viewer framework bypassed this cache entirely. This MR ensures a ::ReadmeBlob is returned instead of a ::Blob when asking a repository for an individual blob, if the commit and path match the readme for HEAD. This makes the cached HTML available to consumers, including the blob viewer. The ReadmeBlob is a simple delegator to the Blob, so should be compatible in all cases. Adding the rendered_markdown method is the only additional behaviour it contains.
Diffstat (limited to 'qa')
0 files changed, 0 insertions, 0 deletions