validateCallbackScheme method

bool validateCallbackScheme(
  1. String callbackUrl
)

Validates the callback URL scheme matches the configuration

Implementation

bool validateCallbackScheme(String callbackUrl) {
  try {
    final uri = Uri.parse(callbackUrl);
    return uri.scheme.toLowerCase() == config.redirectScheme.toLowerCase();
  } catch (e) {
    return false;
  }
}