diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-02-05 16:21:41 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-02-05 16:21:41 +0200 |
commit | a1a01254b903d76e0151b48fa4316add9a6930da (patch) | |
tree | 53c575aba152450f195fbc58035a25e4e2e8218a /app/views/projects/compare | |
parent | 8f88cbf06bce7e88b9a4470645665b65ca543946 (diff) | |
download | gitlab-ce-a1a01254b903d76e0151b48fa4316add9a6930da.tar.gz |
Prevent 500 error on Compare page if diff read timout happens
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/views/projects/compare')
-rw-r--r-- | app/views/projects/compare/show.html.haml | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/app/views/projects/compare/show.html.haml b/app/views/projects/compare/show.html.haml index e0c1b01dfbc..9bd49855369 100644 --- a/app/views/projects/compare/show.html.haml +++ b/app/views/projects/compare/show.html.haml @@ -22,10 +22,14 @@ - if @diffs.present? = render "projects/commits/diffs", diffs: @diffs, project: @project - elsif @commits.size > MergeRequestDiff::COMMITS_SAFE_SIZE - .alert.alert-warning - %p - %strong Warning! This comparison includes more than #{MergeRequestDiff::COMMITS_SAFE_SIZE} commits. + .bs-callout.bs-callout-danger + %h4 This comparison includes more than #{MergeRequestDiff::COMMITS_SAFE_SIZE} commits. %p To preserve performance the line diff is not shown. + - elsif @timeout + .bs-callout.bs-callout-danger + %h4 Diff for this comparison is extremely large. + %p Use command line to browse diff for this comparison. + - else .light-well |