removed some unused module dependencies and moved http request handling in its own method