Added 'Use current location' functionality, fixed some other bugs