NXDRIVE-46: Fix UnboundLocalError in 'deleted' event log