public
Description: Build your fixtures in Ruby.
Homepage: http://errtheblog.com/posts/61-fixin-fixtures
Clone URL: git://github.com/defunkt/fixture_scenarios_builder.git
fix what should have been a local variable assignment
defunkt (author)
Tue Mar 11 23:33:40 -0700 2008
commit  7f7b61462cdd91b3c25beb60de4fad7cae812bff
tree    a549ab2c5d01305cf270df7fcf8432c6450994de
parent  212be98be4a96b242e40afa5b5139e581a528e99
...
104
105
106
107
 
108
109
110
 
111
112
113
...
104
105
106
 
107
108
109
 
110
111
112
113
0
@@ -104,10 +104,10 @@ class ScenarioBuilder
0
 
0
   def record_name(record_hash)
0
     key = [@table_name.classify, record_hash['id'].to_i]
0
- @record_names << (@custom_names[key] || inferred_record_name(record_hash) )
0
+ @record_names << (name = @custom_names[key] || inferred_record_name(record_hash) )
0
     name
0
   end
0
-
0
+
0
   def inferred_record_name(record_hash)
0
     @@record_name_fields.each do |try|
0
       if name = record_hash[try]

Comments

    No one has commented yet.