keyIdFromType method

String? keyIdFromType(
  1. String type
)

Implementation

String? keyIdFromType(String type) {
  final keys = keyIdsFromType(type);
  if (keys == null || keys.isEmpty) {
    return null;
  }
  if (keys.contains(defaultKeyId)) {
    return defaultKeyId;
  }
  return keys.first;
}