Skip to content

Commit

Permalink
Merge pull request #1887 from Shopify/remove-lru-redux
Browse files Browse the repository at this point in the history
remove lru-redux
  • Loading branch information
ggmichaelgo authored Jan 13, 2025
2 parents 0558bd1 + e200c45 commit fe3da0e
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 7 deletions.
5 changes: 1 addition & 4 deletions lib/liquid/context.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# frozen_string_literal: true

require "lru_redux"

module Liquid
# Context keeps the variable stack and resolves variables, as well as keywords
#
Expand Down Expand Up @@ -41,7 +39,6 @@ def initialize(environments = {}, outer_scope = {}, registers = {}, rethrow_erro
@filters = []
@global_filter = nil
@disabled_tags = {}
@expression_cache = LruRedux::ThreadSafeCache.new(1000)

# Instead of constructing new StringScanner objects for each Expression parse,
# we recycle the same one.
Expand Down Expand Up @@ -183,7 +180,7 @@ def []=(key, value)
# Example:
# products == empty #=> products.empty?
def [](expression)
evaluate(Expression.parse(expression, @string_scanner, @expression_cache))
evaluate(Expression.parse(expression, @string_scanner))
end

def key?(key)
Expand Down
2 changes: 0 additions & 2 deletions lib/liquid/expression.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# frozen_string_literal: true

require "lru_redux"

module Liquid
class Expression
LITERALS = {
Expand Down
2 changes: 1 addition & 1 deletion lib/liquid/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
# frozen_string_literal: true

module Liquid
VERSION = "5.6.2"
VERSION = "5.6.3"
end

0 comments on commit fe3da0e

Please sign in to comment.