Don't use generic error for adapter errors.
Remove unused code.