Remove unused variables, fix problem with workSafe function