Fix typo in error handler