Modifying LoginTask. Hoping to get rid of APIQueries class as it is difficult to understand