summaryrefslogtreecommitdiffhomepage
path: root/lib/axlsx/stylesheet/gradient_stop.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/axlsx/stylesheet/gradient_stop.rb')
-rw-r--r--lib/axlsx/stylesheet/gradient_stop.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/axlsx/stylesheet/gradient_stop.rb b/lib/axlsx/stylesheet/gradient_stop.rb
index dd0ea00f..d4df9b3b 100644
--- a/lib/axlsx/stylesheet/gradient_stop.rb
+++ b/lib/axlsx/stylesheet/gradient_stop.rb
@@ -24,14 +24,14 @@ module Axlsx
# @see color
def color=(v) DataTypeValidator.validate "GradientStop.color", Color, v; @color = v end
# @see position
- def position=(v) DataTypeValidator.validate "GradientStop.position", Float, v, lambda { |arg| arg >= 0 && arg <= 1 }; @position = v end
+ def position=(v) DataTypeValidator.validate "GradientStop.position", Float, v, ->(arg) { arg >= 0 && arg <= 1 }; @position = v end
# Serializes the object
# @param [String] str
# @return [String]
def to_xml_string(str = +'')
str << '<stop position="' << position.to_s << '">'
- self.color.to_xml_string(str)
+ color.to_xml_string(str)
str << '</stop>'
end
end