diff options
author | George Claghorn <george@basecamp.com> | 2018-05-16 22:55:09 -0400 |
---|---|---|
committer | George Claghorn <george@basecamp.com> | 2018-05-16 22:55:09 -0400 |
commit | e092cae49cd82df6599765ac49d56796fdcb0cc2 (patch) | |
tree | a11345c9758e9335596a434773889551c76b5839 /activestorage/lib | |
parent | ff3210556b89fdb3fe289117fa72ba3155231442 (diff) | |
download | rails-e092cae49cd82df6599765ac49d56796fdcb0cc2.tar.gz rails-e092cae49cd82df6599765ac49d56796fdcb0cc2.tar.bz2 rails-e092cae49cd82df6599765ac49d56796fdcb0cc2.zip |
Add ActiveStorage::Previewer#tempdir
Diffstat (limited to 'activestorage/lib')
-rw-r--r-- | activestorage/lib/active_storage/previewer.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/activestorage/lib/active_storage/previewer.rb b/activestorage/lib/active_storage/previewer.rb index 30d90493dc..e574b3cf8b 100644 --- a/activestorage/lib/active_storage/previewer.rb +++ b/activestorage/lib/active_storage/previewer.rb @@ -44,7 +44,7 @@ module ActiveStorage # end # end # - # The output tempfile is opened in the directory returned by ActiveStorage::Downloading#tempdir. + # The output tempfile is opened in the directory returned by #tempdir. def draw(*argv) #:doc: ActiveSupport::Notifications.instrument("preview.active_storage") do open_tempfile_for_drawing do |file| @@ -73,5 +73,9 @@ module ActiveStorage def logger #:doc: ActiveStorage.logger end + + def tempdir #:doc: + Dir.tmpdir + end end end |