[WIP] Test transmogrifier

Introduce MobilizonWeb.API namespace

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

Format

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

WIP

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

remove unneeded code

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

Fix tests

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

Fix warnings

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2018-12-14 17:41:55 +01:00
parent e3a8343112
commit c1e6612405
41 changed files with 2961 additions and 246 deletions

View File

@@ -116,7 +116,7 @@ defmodule Mobilizon.Addresses do
rescue
e in ArgumentError ->
Logger.error("#{type_input} is not an existing atom : #{inspect(e)}")
nil
:invalid_type
end
else
type_input
@@ -128,7 +128,7 @@ defmodule Mobilizon.Addresses do
process_point(data["latitude"], data["longitude"])
end
else
{:error, nil}
{:error, :invalid_type}
end
end