getAttribute method
Implementation
@override
Future<String?> getAttribute(String key) async {
if (!kCanTrace) {
logger?.debug(this, 'Sentry Trace is not allowed to trace');
return null;
}
if (kInstance == null) {
logger?.error(this, 'Sentry Trace is not initialized');
return null;
}
if (key.isEmpty) {
logger?.error(this, 'Key cannot be empty when getting the attribute');
return null;
}
logger?.debug(this, 'Getting attribute:$key, from Sentry Trace');
return _attributes[key];
}