mylocation function called properly