Optimize checking for interrupts by replacing any? with NOT empty?

This commit is contained in:
Jason Hiltz-Laforge
2014-07-15 18:31:40 +00:00
parent c4bc6cf3db
commit 4cfc05e32a

View File

@@ -73,7 +73,7 @@ module Liquid
# are there any not handled interrupts?
def has_interrupt?
@interrupts.any?
!@interrupts.empty?
end
# push an interrupt to the stack. this interrupt is considered not handled.