Skip to content

Commit

Permalink
1.11.2
Browse files Browse the repository at this point in the history
  • Loading branch information
arnaudlevy committed Feb 23, 2022
1 parent fd601e4 commit 1da88db
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
kamifusen (1.11.1)
kamifusen (1.11.2)
image_processing
rails

Expand Down
6 changes: 3 additions & 3 deletions app/views/kamifusen/_view.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -78,14 +78,14 @@ end
%>
<picture<%= " class=\"#{picture_class}\"".html_safe unless picture_class.blank? %>>
<% if Kamifusen.with_webp %>
<source srcset="<%= srcset_webp %>"
<source srcset="<%= raw srcset_webp %>"
<%= " sizes=\"#{sizes_value}\"".html_safe unless sizes.empty? %>
type="image/webp">
<% end %>
<source srcset="<%= srcset_default %>"
<source srcset="<%= raw srcset_default %>"
<%= " sizes=\"#{sizes_value}\"".html_safe unless sizes.empty? %>
type="<%= source.content_type %>">
<img src="<%= default %>" <%= raw parameters %>>
<img src="<%= raw default %>" <%= raw parameters %>>
</picture>
<% else %>
<picture>
Expand Down
6 changes: 3 additions & 3 deletions lib/kamifusen/processor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ def url
def keycdn_url
url = "#{Kamifusen.keycdn}/#{variant.blob.key}?"
transformations = variant.variation.transformations
url += "&format=#{transformations[:format]}" if transformations.has_key? :format
url += "&quality=#{transformations[:quality]}" if transformations.has_key? :quality
url += "format=#{transformations[:format]}&" if transformations.has_key? :format
url += "quality=#{transformations[:quality]}&" if transformations.has_key? :quality
if transformations.has_key? :resize
resize = transformations[:resize]
# 100>
if '>'.in? resize
width = resize.split('>').first.to_i
url += "&width=#{width}"
url += "width=#{width}&"
end
end
url
Expand Down
2 changes: 1 addition & 1 deletion lib/kamifusen/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Kamifusen
VERSION = "1.11.1"
VERSION = "1.11.2"
end

0 comments on commit 1da88db

Please sign in to comment.