Skip to content

Commit 3b30eb9

Browse files
committed
fix(community_management): remove redundant condition in comment status filter
- Remove unnecessary check for ModerationStatus.resolved - Simplify the condition by directly using the selected status
1 parent 538bf4b commit 3b30eb9

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

lib/community_management/bloc/community_management_bloc.dart

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,11 +111,7 @@ class CommunityManagementBloc
111111
}
112112

113113
if (filter.selectedStatus != null) {
114-
if (filter.selectedStatus == ModerationStatus.resolved) {
115-
conditions.add({'comment.status': ModerationStatus.resolved.name});
116-
} else {
117-
conditions.add({'comment.status': filter.selectedStatus!.name});
118-
}
114+
conditions.add({'comment.status': filter.selectedStatus!.name});
119115
}
120116

121117
if (conditions.isEmpty) {

0 commit comments

Comments
 (0)