flex icon indicating copy to clipboard operation
flex copied to clipboard

API functions don't accept keyword list as argument

Open sebb7 opened this issue 7 years ago • 0 comments

iex(4)> Flex.API.create_db("my_db", host: "http://localhost:8086")
** (BadMapError) expected a map, got: [host: "http://localhost:8086"]
    (elixir) lib/map.ex:667: Map.drop([host: "http://localhost:8086"], [])
    (flex) lib/flex/api.ex:286: Flex.API.check_params/3
    (flex) lib/flex/api.ex:234: Flex.API.do_post_to_read_endpoint/4
iex(9)> Flex.API.get_databases(host: "http://localhost:8086")                                                                                                                               
** (BadMapError) expected a map, got: [host: "http://localhost:8086"]
    (elixir) lib/map.ex:667: Map.drop([host: "http://localhost:8086"], [])
    (flex) lib/flex/api.ex:286: Flex.API.check_params/3
    (flex) lib/flex/api.ex:224: Flex.API.do_get_to_read_endpoint/4

sebb7 avatar Jul 16 '18 13:07 sebb7