refactoring: add error log for sentry