nats.go icon indicating copy to clipboard operation
nats.go copied to clipboard

UserCredentials should return error

Open tvojacek opened this issue 2 years ago • 0 comments

Feature Request

UserCredentials call userFromFile and ignore error change UserCredentials to return error

Use Case:

Changed signature show the truth that the function can fail. and simply debug for such error.

Proposed Change:

change UserCredentials to return error

Who Benefits From The Change(s)?

Api will be more consistent, similar function NkeyOptionFromSeed already return error. Connection error will be easier to debug.

Alternative Approaches

Define new function instead of change api of old one. or Log error to not be hidden.

tvojacek avatar Sep 26 '22 21:09 tvojacek