Fixes lock file removal