Module: Imgproxy::Extensions::Shrine
- Defined in:
- lib/imgproxy/extensions/shrine.rb
Overview
Extension for Shrine::UploadedFile
Instance Method Summary collapse
-
#imgproxy_info_url(options = {}) ⇒ String
Returns imgproxy info URL for a Shrine::UploadedFile instance.
-
#imgproxy_url(options = {}) ⇒ String
Returns imgproxy URL for a Shrine::UploadedFile instance.
Instance Method Details
#imgproxy_info_url(options = {}) ⇒ String
Returns imgproxy info URL for a Shrine::UploadedFile instance
23 24 25 26 |
# File 'lib/imgproxy/extensions/shrine.rb', line 23 def imgproxy_info_url( = {}) return .info_url_for(self) if .is_a?(Imgproxy::UrlBuilders::Info) Imgproxy.info_url_for(self, ) end |
#imgproxy_url(options = {}) ⇒ String
Returns imgproxy URL for a Shrine::UploadedFile instance
13 14 15 16 |
# File 'lib/imgproxy/extensions/shrine.rb', line 13 def imgproxy_url( = {}) return .url_for(self) if .is_a?(Imgproxy::UrlBuilders::Processing) Imgproxy.url_for(self, ) end |