Make UUID in JsonAddress optional

This commit is contained in:
Maarten Everts 2020-09-04 16:09:43 +02:00
parent 97a6747924
commit 9248417773

View file

@ -2,7 +2,7 @@ package v1
// JsonAddress is a signal user's contact information. a phone number, UUID or both // JsonAddress is a signal user's contact information. a phone number, UUID or both
type JsonAddress struct { type JsonAddress struct {
UUID string `json:"uuid"` UUID string `json:"uuid,omitempty"`
Number string `json:"number"` Number string `json:"number"`
} }
@ -26,7 +26,7 @@ type JsonReadMessage struct {
type JsonSendMessageResult struct { type JsonSendMessageResult struct {
Address JsonAddress `json:"address"` Address JsonAddress `json:"address"`
Success Success `json:"success"` Success Success `json:"success"`
NetworkFailure bool `json:"networkFailure"` NetworkFailure bool `json:"networkFailure"`
UnregisteredFailure bool `json:"unregisteredFailure"` UnregisteredFailure bool `json:"unregisteredFailure"`
IdentityFailure string `json:"identityFailure"` IdentityFailure string `json:"identityFailure"`