featureFlagDetail method
Implementation
@override
Future<FeatureFlagDecision> featureFlagDetail(
int featureKey, {
HackleUser? user,
}) async {
try {
final Map<String, Object?> arguments = {
Argument.featureKey.value: featureKey,
Argument.user.value: user?.toMap(),
};
final Map<dynamic, dynamic> result = await methodChannel.invokeMethod(
Method.featureFlagDetail.value,
arguments,
);
return result.toFeatureFlagDecision();
} catch (e) {
log("Failed to featureFlagDetail", level: 3, error: e);
return FeatureFlagDecision.of(
isOn: false, reason: DecisionReason.EXCEPTION);
}
}