Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: populate empty SNIs with an empty array
Kong returns back an empty JSON array instead of a `null` when the SNI array is empty: ``` { "data": [ { "cert": "-truncated-", "created_at": 1584219121, "id": "3e83146b-7139-4306-aa0c-f95ba3a9e315", "key": "-truncated-", "snis": [], "tags": null } ], "next": null } ``` Kong deviates from it's regular behavior of returning a `null`. This causes decK to detect a diff an existing and desired certificate because the two certificates have different empty SNIs, one has an empty array ([]*string{}) while the other is `nil`. This commit populates a nil SNIs field with an empty array. This bug only shows up when there are no SNIs associates with a certificate in Kong. Fix #131 From #132
- Loading branch information