Fixed bug in locked location logic