diff options
author | utilum <oz@utilum.com> | 2018-06-28 19:34:28 +0200 |
---|---|---|
committer | utilum <oz@utilum.com> | 2018-06-29 07:58:28 +0200 |
commit | 875ef6e74878dfd60e334901bb478f2cf7667d90 (patch) | |
tree | bcbbb2f9b1eb20badea4fe3c58407296c32562c8 /activestorage/lib | |
parent | 08dde0f355e0450bc2cb7e0b4b95a0ec18d1a870 (diff) | |
download | rails-875ef6e74878dfd60e334901bb478f2cf7667d90.tar.gz rails-875ef6e74878dfd60e334901bb478f2cf7667d90.tar.bz2 rails-875ef6e74878dfd60e334901bb478f2cf7667d90.zip |
Tweak Previewer::PopplerPDFPreviewer#pdftoppm_exists?
Does not warn `instance variable @pdftoppm_exists not initialized`.
Diffstat (limited to 'activestorage/lib')
-rw-r--r-- | activestorage/lib/active_storage/previewer/poppler_pdf_previewer.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activestorage/lib/active_storage/previewer/poppler_pdf_previewer.rb b/activestorage/lib/active_storage/previewer/poppler_pdf_previewer.rb index 2a787362cf..69eb617d7b 100644 --- a/activestorage/lib/active_storage/previewer/poppler_pdf_previewer.rb +++ b/activestorage/lib/active_storage/previewer/poppler_pdf_previewer.rb @@ -12,7 +12,7 @@ module ActiveStorage end def pdftoppm_exists? - return @pdftoppm_exists unless @pdftoppm_exists.nil? + return @pdftoppm_exists if defined?(@pdftoppm_exists) @pdftoppm_exists = system(pdftoppm_path, "-v", out: File::NULL, err: File::NULL) end |