better fix for worker error bug