Skip to content

Conversation

@cgunther
Copy link
Contributor

@cgunther cgunther commented Mar 6, 2024

Previously respond_to? assumed it was given a symbol argument, so it directly checked for that argument in the fields, which are force-keyed as symbols. If you passed it a string argument, it wouldn't find the corresponding field, impying it didn't respond to such a method.

Now, the argument is explicitly cast to a symbol before checking if such a field exists, supporting checking respond_to? with both argument types.

Previously `respond_to?` assumed it was given a symbol argument, so it
directly checked for that argument in the fields, which are force-keyed
as symbols. If you passed it a string argument, it wouldn't find the
corresponding field, impying it didn't respond to such a method.

Now, the argument is explicitly cast to a symbol before checking if such
a field exists, supporting checking `respond_to?` with both argument
types.
@cgunther cgunther force-pushed the custom-field-list-respond-to-string branch from 37dec19 to 83584cc Compare March 6, 2024 19:49
@cgunther
Copy link
Contributor Author

cgunther commented Mar 6, 2024

CI is failing because of an upstream change in Nori, which can be fixed by #607

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant