Validatex v1.0.1 Validatex.MapExtra View Source
A map functions.
Link to this section Summary
Functions
Gets the value for a specific key in map. If key isn't present in map,
the RuntimeError will be raised.
Link to this section Functions
Gets the value for a specific key in map. If key isn't present in map,
the RuntimeError will be raised.
iex> Validatex.MapExtra.get!(%{"name" => "Foo"}, "name")
"Foo"
iex> Validatex.MapExtra.get!(%{"name" => "Foo"}, "surname")
** (RuntimeError) Key 'surname' not found in '%{"name" => "Foo"}'.