onError method
Global error handler for this adapter's lifecycle.
Called whenever an error occurs during onBind, onInit, or onDispose.
error The exception or object thrown.
stackTrace The stack trace associated with the error.
Implementation
void onError(Object error, StackTrace stackTrace) {
debugPrint('[Adapter:$id] Error: $error');
debugPrint(stackTrace.toString());
}