Closed patrickpichler closed 6 months ago
/gcbrun
Thanks @patrickpichler! This seems like a very nice win.
Wow I just discovered this PR after creating #942! My PR fixes an issue not fixed in yours but completely related to the same use-case
@TristonianJones I've updated the code, would be nice if you could have another look :)
/gcbrun
@patrickpichler thanks for the contribution!
In order to customize how to fields of native types can be accessed via CEL, struct tag support has been added. It is now possible to provide a struct field tag, that will act as the name for the corresponding field.
Here an example
and here is how to access the
Age
field from CEL:Pull Requests Guidelines
See CONTRIBUTING.md for more details about when to create a GitHub [Pull Request][1] and when other kinds of contributions or consultation might be more desirable.
When creating a new pull request, please fork the repo and work within a development branch.
Commit Messages
Background on why the change is being made with additional detail on consequences of the changes elsewhere in the code or to the general functionality of the library. Multiple paragraphs may be used, but please keep lines to 72 characters or less.