Skip to content

Commit 961bee3

Browse files
committed
Fix support of string headers
1 parent 4c2ae1f commit 961bee3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/active_admin/axlsx/builder.rb

+2-2
Original file line numberDiff line numberDiff line change
@@ -141,15 +141,15 @@ def serialize(collection)
141141
class Column
142142

143143
def initialize(name, block = nil)
144-
@name = name.to_sym
144+
@name = name
145145
@data = block || @name
146146
end
147147

148148
attr_reader :name, :data
149149

150150
def localized_name(i18n_scope = nil)
151151
return name.to_s.titleize unless i18n_scope
152-
I18n.t name, scope: i18n_scope
152+
I18n.t name.to_sym, scope: i18n_scope
153153
end
154154
end
155155

0 commit comments

Comments
 (0)