diff options
Diffstat (limited to 'lib/evendoors')
-rw-r--r-- | lib/evendoors/spin.rb | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/evendoors/spin.rb b/lib/evendoors/spin.rb index 1316c82..69d204d 100644 --- a/lib/evendoors/spin.rb +++ b/lib/evendoors/spin.rb @@ -35,17 +35,15 @@ module EvenDoors @debug_routing = o[:debug_routing]||o['debug_routing']||false # if not o.empty? + p ={'parent'=>self} o['spots'].each do |name,spot| - spot['parent']=self - EvenDoors::Room.json_create(spot) + EvenDoors::Room.json_create(spot.merge!(p)) end if o['spots'] o['app_fifo'].each do |particle| - particle['parent']=self - @app_fifo << EvenDoors::Particle.json_create(particle) + @app_fifo << EvenDoors::Particle.json_create(particle.merge!(p)) end if o['app_fifo'] o['sys_fifo'].each do |particle| - particle['parent']=self - @sys_fifo << EvenDoors::Particle.json_create(particle) + @sys_fifo << EvenDoors::Particle.json_create(particle.merge!(p)) end if o['sys_fifo'] end end |