commit 96c887985bd829dc0ed80e4802a6e7ba3a42e789
parent 377185f7b359728598838d2968a73d1947acda6f
Author: Suraj N. Kurapati <sunaku@gmail.com>
Date: Wed, 13 May 2009 21:53:06 -0700
fix order of client tag mapping specified in YAML was not respected
(bug reported by Michael Andrus)
Diffstat:
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/config.rb b/config.rb
@@ -268,13 +268,10 @@ def load_config config_file
client = Client.new(client_id)
unless defined? @client_tags_by_regexp
- # compile the regular expression only once
- pairs = CONFIG['display']['client'].map {|hash|
+ @client_tags_by_regexp = CONFIG['display']['client'].map {|hash|
k, v = hash.to_a.first
[eval(k, TOPLEVEL_BINDING, "#{config_file}:display:client"), v]
}
-
- @client_tags_by_regexp = Hash[*pairs.flatten]
end
if label = client.props.read rescue nil