fatal static method
Implementation
static Future<void> fatal(String message, {Object? error, StackTrace? stackTrace, String? category, String? tag, Map<String, dynamic>? metadata, bool shouldNotify = false}) async {
if (!instance._initialized) {
throw StateError('VooLogger must be initialized before use');
}
await instance._repository.fatal(message, error: error, stackTrace: stackTrace, category: category, tag: tag, metadata: metadata);
if (shouldNotify) {
VooToast.showError(
message: message,
title: category ?? 'Fatal Error',
duration: const Duration(seconds: 10), // Longer duration for fatal errors
);
}
}