File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -165,7 +165,9 @@ void showTopicActionSheet(BuildContext context, {
165165
166166 final visibilityOptions = < UserTopicVisibilityPolicy > [];
167167 final visibilityPolicy = store.topicVisibilityPolicy (channelId, topic);
168- if (subscription != null && ! subscription.isMuted) {
168+ if (subscription == null ) {
169+ // Not subscribed to the channel; there is no user topic change to be made.
170+ } else if (! subscription.isMuted) {
169171 // Channel is subscribed and not muted.
170172 switch (visibilityPolicy) {
171173 case UserTopicVisibilityPolicy .muted:
@@ -189,7 +191,7 @@ void showTopicActionSheet(BuildContext context, {
189191 // our data structures.
190192 assert (false );
191193 }
192- } else if (subscription != null && subscription.isMuted) {
194+ } else {
193195 // Channel is muted.
194196 if (supportsUnmutingTopics) {
195197 switch (visibilityPolicy) {
@@ -215,8 +217,6 @@ void showTopicActionSheet(BuildContext context, {
215217 assert (false );
216218 }
217219 }
218- } else {
219- // Not subscribed to the channel; there is no user topic change to be made.
220220 }
221221 optionButtons.addAll (visibilityOptions.map ((to) {
222222 return UserTopicUpdateButton (
You can’t perform that action at this time.
0 commit comments