What is Nostr?
amos /
npub1n6r…k065
2023-03-04 08:44:42
in reply to nevent1q…fvdc

amos on Nostr: Usually there's two variants of a function in elixir, one that ends with ! and can ...

Usually there's two variants of a function in elixir, one that ends with ! and can throw an exception, and one that will return either {:error, result} or {:ok, result}.
I usually use the first option if I know there is no chance something will fail or I don't care if it fails, and the second option if I know there is a chance it will fail and I want to catch the error. Of course you can also catch exceptions, but I do that more as a catchall if I really don't want a process to crash.
Author Public Key
npub1n6rlug259nhkkyrkxd84uq0kzn9ut04zyvv8kpudadru9aezqkmqwkk065