matchRegexProtocol function

bool matchRegexProtocol(
  1. String url,
  2. String regex
)

Implementation

bool matchRegexProtocol(String url, String regex) {
  final protocol = getUrlProtocol(url);
  if (protocol == null) return false;
  return RegExp(regex).hasMatch(protocol);
}