setRequiresConsent static method
- @Deprecated('This function is deprecated, please use "setRequiresConsent" of CountlyConfig instead')
- bool flag
Set that consent should be required for features to work. Should be call before Countly init returns the error or success message
Implementation
@Deprecated('This function is deprecated, please use "setRequiresConsent" of CountlyConfig instead')
static Future<String?> setRequiresConsent(bool flag) async {
log('Calling "setRequiresConsent":[$flag]');
log('setRequiresConsent is deprecated, use setRequiresConsent of CountlyConfig instead', logLevel: LogLevel.WARNING);
List<String> args = [];
args.add(flag.toString());
final String? result = await _channel.invokeMethod('setRequiresConsent', <String, dynamic>{'data': json.encode(args)});
return result;
}