isSupported method

  1. @override
Future<bool> isSupported()
override

Returns true if the XEP is supported on the server. If not, returns false

Implementation

@override
Future<bool> isSupported() async {
  if (_gotSupported) return _supported;

  // Query the server
  final disco = getAttributes().getManagerById<DiscoManager>(discoManager)!;
  _supported = await disco.supportsFeature(
    getAttributes().getConnectionSettings().serverJid,
    carbonsXmlns,
  );
  _gotSupported = true;
  return _supported;
}