Skip to content

Instantly share code, notes, and snippets.

@leandrocp
Last active November 14, 2018 09:59
Show Gist options
  • Save leandrocp/5125cb8b11230df8f3eba21679426974 to your computer and use it in GitHub Desktop.
Save leandrocp/5125cb8b11230df8f3eba21679426974 to your computer and use it in GitHub Desktop.
art_bc_support_public_api.ex
# apps/support/lib/support.ex
defmodule Support do
def get_customer(customer_id) when is_integet(customer_id) do
find(customer_id) # get customer from db
|> Map.from_struct()
end
end
@max5it
Copy link

max5it commented Nov 3, 2018

I guess "is_integet" should be "is_integer".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment