worker: fix typo in on_error handler