You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We came across this when updating the to latest version.
The metadata generation is using .to_str to get the attribute value. to_str is only defined on String values, which is throwing a 500 error for our configuration that has boolean attribute values.
This may be the intended behavior, and perhaps we should always be using a string but I wanted to check.
We came across this when updating the to latest version.
The metadata generation is using
.to_str
to get the attribute value.to_str
is only defined on String values, which is throwing a 500 error for our configuration that has boolean attribute values.This may be the intended behavior, and perhaps we should always be using a string but I wanted to check.
Our configuration has a line like this:
This line causes a 500 error because
attribute_value
is boolean, even thoughtrue.to_s
would work just fine and converttrue
to"true"
.Personally, I like the way it reads being a boolean value and it allows an easy way to support methods that return boolean responses like this:
The impact of using
.to_s
vs.to_str
seems very minimal, but I'd love to know if there is a more complicated reason for the choice.If there isn't, I'm happy to submit a PR.
The text was updated successfully, but these errors were encountered: