Skip to content

Commit

Permalink
Merge pull request #8 from gadabout/fix-filter-params
Browse files Browse the repository at this point in the history
Fix some filter params edge cases.
  • Loading branch information
Chris Dosé committed Oct 12, 2016
2 parents a974aef + 081fc82 commit c33de83
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/lurch/param_builder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def encode_value(value, key = nil)
when Array then value.map { |v| encode_value(v, "#{key}[]") }.reject(&:empty?).join("&")
when nil then ""
else
"#{key}=#{CGI.escape(value.to_s)}"
value.to_s.empty? ? "" : "#{key}=#{CGI.escape(value.to_s)}"
end
end

Expand Down
2 changes: 1 addition & 1 deletion lib/lurch/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module Lurch
VERSION = "0.0.7".freeze
VERSION = "0.0.8".freeze
end

0 comments on commit c33de83

Please sign in to comment.