lorenzodonini / ocpp-go

Open Charge Point Protocol implementation in Go
MIT License
275 stars 126 forks source link

Make ConfigurationKey specification compatible with ocpp1.6 #108

Closed utsavanand2 closed 3 years ago

utsavanand2 commented 3 years ago

Issue

Make the ConfigurationKey struct's ReadOnly element required

Description

While going through the OCPP 1.6 documentation around KeyValue for GetConfiguration, I noticed, readonly is described as required.

Screenshot 2021-08-04 at 4 59 11 PM

Possible Solution

If it was missed out, I'm linking a PR that fixes it.

utsavanand2 commented 3 years ago

Just realised that the bool will have a default value anyway, and hence the required tag of the validator is not "required" (no pun intended) at all.

For reference: https://github.com/go-playground/validator/issues/319