Added function to cancel mapping