replaces a delete command with unlink