Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve copyStruct() function to be case insensitive #213

Closed
maksym-nazarenko opened this issue Nov 23, 2023 · 0 comments · Fixed by #215
Closed

Improve copyStruct() function to be case insensitive #213

maksym-nazarenko opened this issue Nov 23, 2023 · 0 comments · Fixed by #215
Labels
enhancement New feature or request provider

Comments

@maksym-nazarenko
Copy link
Collaborator

Currently, copyStruct() func is searching fields in the target struct by the field's name.
This search is done by 1-to-1 mapping of field names, so ID != Id.

This behavior should be changed, so fields mapping is done in a better way.
Options are:

  1. case-insensitive search (probably, easier in short term)
  2. use struct tags for field naming (requires adding tags to all models in Terraform resources and MikroTik client packages)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request provider
Projects
None yet
2 participants