lib/slippery/processors/impress_js/auto_offsets.rb in slippery-0.0.3 vs lib/slippery/processors/impress_js/auto_offsets.rb in slippery-0.1.0
- old
+ new
@@ -8,10 +8,10 @@
end
def call(doc)
doc.replace('.step') do |step|
['data-x', 'data-y'].each_with_index do |axis, idx|
- if step.attr?(axis)
+ if step.has_attr?(axis)
@position[idx] = step[axis].to_i
else
@position[idx] += @offsets[idx]
end
end