Ticket 74 improve error handling

https://github.com/easy-wi/developer/issues/74