Added additional checks to move functions