Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add custom marshallers for some ABAC types.
Javascript really does not like to get a null when it expects an empty array, but that's what Go will send if your struct contains e.g. a []string and you don't explicitly initialize the slice. These custom marshallers make sure we send an empty array, making the frontend's life easier. Go desperately needs some way to tell the JSON encoder that we want this behavior, see: golang/go#37711 golang/go#27589 golang/go#27813
- Loading branch information