Skip to content

Commit 906df5b

Browse files
fingertricksmikeproeng37
authored andcommitted
fix: Add @nullable annotation to getNotificationCenter() (#222)
1 parent 6d36538 commit 906df5b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

android-sdk/src/main/java/com/optimizely/ab/android/sdk/OptimizelyClient.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -553,9 +553,11 @@ String getFeatureVariableString(@NonNull String featureKey,
553553
/**
554554
* Return the notification center {@link NotificationCenter} used to add notifications for events
555555
* such as Activate and track.
556-
* @return
556+
* @return The {@link NotificationCenter} or null if Optimizely is not initialized (or
557+
* initialization failed)
557558
*/
558-
public NotificationCenter getNotificationCenter() {
559+
public @Nullable
560+
NotificationCenter getNotificationCenter() {
559561
if (isValid()) {
560562
return optimizely.notificationCenter;
561563
} else {

0 commit comments

Comments
 (0)