46 lines
1.9 KiB
Java
46 lines
1.9 KiB
Java
package com.discord.widgets.settings;
|
|
|
|
import com.discord.models.experiments.domain.Experiment;
|
|
import com.discord.stores.StoreStream;
|
|
import d0.g;
|
|
import d0.z.d.m;
|
|
import kotlin.Lazy;
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
import rx.Observable;
|
|
/* compiled from: CustomProfilesEditingFeatureFlag.kt */
|
|
public final class CustomProfilesEditingFeatureFlag {
|
|
public static final Companion Companion = new Companion(null);
|
|
private static final Lazy INSTANCE$delegate = g.lazy(CustomProfilesEditingFeatureFlag$Companion$INSTANCE$2.INSTANCE);
|
|
|
|
/* compiled from: CustomProfilesEditingFeatureFlag.kt */
|
|
public static final class Companion {
|
|
private Companion() {
|
|
}
|
|
|
|
public /* synthetic */ Companion(DefaultConstructorMarker defaultConstructorMarker) {
|
|
this();
|
|
}
|
|
|
|
public final CustomProfilesEditingFeatureFlag getINSTANCE() {
|
|
Lazy access$getINSTANCE$cp = CustomProfilesEditingFeatureFlag.access$getINSTANCE$cp();
|
|
Companion companion = CustomProfilesEditingFeatureFlag.Companion;
|
|
return (CustomProfilesEditingFeatureFlag) access$getINSTANCE$cp.getValue();
|
|
}
|
|
}
|
|
|
|
public static final /* synthetic */ Lazy access$getINSTANCE$cp() {
|
|
return INSTANCE$delegate;
|
|
}
|
|
|
|
public final boolean isEnabled() {
|
|
Experiment userExperiment = StoreStream.Companion.getExperiments().getUserExperiment("2021-06_android_custom_profiles_editing", true);
|
|
return userExperiment != null && userExperiment.getBucket() == 1;
|
|
}
|
|
|
|
public final Observable<Boolean> observeIsEnabled() {
|
|
Observable<R> F = StoreStream.Companion.getExperiments().observeUserExperiment("2021-06_android_custom_profiles_editing", true).F(CustomProfilesEditingFeatureFlag$observeIsEnabled$1.INSTANCE);
|
|
m.checkNotNullExpressionValue(F, "StoreStream.getExperimen…riment?.bucket == 1\n }");
|
|
return F;
|
|
}
|
|
}
|