You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While Send takes a Message it returns a *Message. Send uses SendMultiple which works on Message only. Internally, receive works on Messages only. I suggest to change the Send signature to return a Message and modify NewMessage accordingly.
The text was updated successfully, but these errors were encountered:
An alternative approach would of course be to use pointer to message consistently throughout. That would make for simpler error return values (nil instead of Message{}).
Hm... good point.
Still thinking ... to be honest I tend to like pointer everywhere more. Both would be breaking changes, but I assume expect you only the cmd utility is used by others (at least as I know).
While Send takes a Message it returns a *Message. Send uses SendMultiple which works on Message only. Internally, receive works on Messages only. I suggest to change the Send signature to return a Message and modify NewMessage accordingly.
The text was updated successfully, but these errors were encountered: