It was due to my emulator having lost the WIFI connection. After refreshing it, it started working for me.