mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-12 23:40:45 -07:00
Add raggi's change to History, remove Ruby 1.8 code from test
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
## 3.0.0 / not yet released / branch "master"
|
||||
|
||||
* ...
|
||||
* Add a class cache to avoid runtime extend calls, see #249 [James Tucker, raggi]
|
||||
* Remove some legacy Ruby 1.8 compatibility code, see #276 [Florian Weingarten, fw42]
|
||||
* Add default filter to standard filters, see #267 [Derrick Reimer, djreimer]
|
||||
* Add optional strict parsing and warn parsing, see #235 [Tristan Hume, trishume]
|
||||
|
||||
@@ -41,8 +41,8 @@ module Liquid
|
||||
@@strainer_class_cache
|
||||
end
|
||||
|
||||
def self.create(context, filters = nil)
|
||||
filters = @@filters + (filters || [])
|
||||
def self.create(context, filters = [])
|
||||
filters = @@filters + filters
|
||||
strainer_class_cache[filters].new(context)
|
||||
end
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@ class StrainerTest < Test::Unit::TestCase
|
||||
assert_kind_of Strainer, strainer
|
||||
assert_kind_of a, strainer
|
||||
assert_kind_of b, strainer
|
||||
Strainer.send(:class_variable_get, :@@filters).each do |m|
|
||||
Strainer.class_variable_get(:@@filters).each do |m|
|
||||
assert_kind_of m, strainer
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user