mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-19 10:52:48 -07:00
Merge branch 'freeze_all_the_things'
Conflicts: History.md lib/liquid/tags/assign.rb lib/liquid/tags/capture.rb lib/liquid/tags/decrement.rb lib/liquid/tags/if.rb
This commit is contained in:
@@ -44,7 +44,7 @@ module Liquid
|
||||
class LocalFileSystem
|
||||
attr_accessor :root
|
||||
|
||||
def initialize(root, pattern = "_%s.liquid")
|
||||
def initialize(root, pattern = "_%s.liquid".freeze)
|
||||
@root = root
|
||||
@pattern = pattern
|
||||
end
|
||||
@@ -59,7 +59,7 @@ module Liquid
|
||||
def full_path(template_path)
|
||||
raise FileSystemError, "Illegal template name '#{template_path}'" unless template_path =~ /\A[^.\/][a-zA-Z0-9_\/]+\z/
|
||||
|
||||
full_path = if template_path.include?('/')
|
||||
full_path = if template_path.include?('/'.freeze)
|
||||
File.join(root, File.dirname(template_path), @pattern % File.basename(template_path))
|
||||
else
|
||||
File.join(root, @pattern % template_path)
|
||||
|
||||
Reference in New Issue
Block a user