From fe80334f213e3dc149f560a50d90d09054f519fe Mon Sep 17 00:00:00 2001 From: sato-s Date: Sun, 9 Oct 2016 21:47:10 +0900 Subject: Fix #472: worksheet name with underscore Previously, worksheet name was defined as a serializable_attributes that Axlsx automatically camelize by Axlsx.camel . This cause an unexpected worksheet name convertion. For instance, - "Pie_chart" is converted into "Piechart" - "_example" is converted into "Example" This patch disables an unexpected worksheet name convertion. --- lib/axlsx/workbook/worksheet/worksheet.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/axlsx/workbook/worksheet/worksheet.rb b/lib/axlsx/workbook/worksheet/worksheet.rb index 1d35b99d..26be8bd8 100644 --- a/lib/axlsx/workbook/worksheet/worksheet.rb +++ b/lib/axlsx/workbook/worksheet/worksheet.rb @@ -27,7 +27,7 @@ module Axlsx yield self if block_given? end - serializable_attributes :sheet_id, :name, :state + serializable_attributes :sheet_id, :state # Initalizes page margin, setup and print options # @param [Hash] options Options passed in from the initializer @@ -597,6 +597,7 @@ module Axlsx add_autofilter_defined_name_to_workbook str << '') end -- cgit v1.2.3