diff options
| author | Paul Kmiec <[email protected]> | 2023-05-15 23:26:13 -0700 |
|---|---|---|
| committer | Paul Kmiec <[email protected]> | 2023-05-15 23:37:33 -0700 |
| commit | 2b42f259552dd3f443a1393eb8b47e8dc9ee80f2 (patch) | |
| tree | 8252cf95d9eb28cb15bfe40193702b501c799c6c /lib | |
| parent | a4ba108eb33cba35f87370b7e4b47bff18130e89 (diff) | |
| download | caxlsx-2b42f259552dd3f443a1393eb8b47e8dc9ee80f2.tar.gz caxlsx-2b42f259552dd3f443a1393eb8b47e8dc9ee80f2.zip | |
Booleanize as string instead of 0 / 1 only to call to_s
The `booleanize` method is always used to pipe values
to str, so it is safe to return the boolean values as
strings.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/axlsx.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/axlsx.rb b/lib/axlsx.rb index 776ff918..656db8aa 100644 --- a/lib/axlsx.rb +++ b/lib/axlsx.rb @@ -171,8 +171,7 @@ module Axlsx # @return [Object] def self.booleanize(value) if value == true || value == false - # value ? '1' : '0' - value ? 1 : 0 + value ? '1' : '0' else value end |
