From 0139f8d5e5e990a1a2cd514df881648472e5f3cf Mon Sep 17 00:00:00 2001 From: ISHITOYA Kentaro Date: Thu, 1 Mar 2012 22:31:05 +0900 Subject: [PATCH] Switched order of evaluation. Because I could not generate language file from strings.txt without 'tags' option. --- lib/twine/stringsfile.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/twine/stringsfile.rb b/lib/twine/stringsfile.rb index 3d82a15..adf3a31 100644 --- a/lib/twine/stringsfile.rb +++ b/lib/twine/stringsfile.rb @@ -23,12 +23,12 @@ module Twine end def matches_tags?(tags) - if @tags == nil || @tags.length == 0 - # This row has no tags. Never match - return false - elsif tags == nil || tags.length == 0 + if tags == nil || tags.length == 0 # The user did not specify any tags. Everything passes. return true + elsif @tags == nil || @tags.length == 0 + # This row has no tags. Never match + return false else tags.each do |tag| if @tags.include? tag