add customer error handler
add QiriError to handler errors
remove unused code