normalizing callbacks with errors
new error: invalid_code