summaryrefslogtreecommitdiff
path: root/app/models/blob.rb
diff options
context:
space:
mode:
authorDouwe Maan <douwe@selenight.nl>2017-06-06 16:22:28 -0500
committerDouwe Maan <douwe@selenight.nl>2017-06-07 14:31:05 -0500
commiteee712c82f642320922b9e99e9034a2ce6464591 (patch)
tree368ea1830796c90b64f44a1423e8ecc4f93923dd /app/models/blob.rb
parentfc1090d9f39231e31f929e37b9703db9738b457c (diff)
downloadgitlab-ce-eee712c82f642320922b9e99e9034a2ce6464591.tar.gz
Empty blob viewer isn’t binary-onlydm-empty-blob-viewer-binary
Diffstat (limited to 'app/models/blob.rb')
-rw-r--r--app/models/blob.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/blob.rb b/app/models/blob.rb
index 6a42a12891c..bba23bbb7e0 100644
--- a/app/models/blob.rb
+++ b/app/models/blob.rb
@@ -176,7 +176,7 @@ class Blob < SimpleDelegator
end
def rendered_as_text?(ignore_errors: true)
- simple_viewer.text? && (ignore_errors || simple_viewer.render_error.nil?)
+ simple_viewer.is_a?(BlobViewer::Text) && (ignore_errors || simple_viewer.render_error.nil?)
end
def show_viewer_switcher?