Skip to content

Commit f99f66b

Browse files
committed
channel: Remove an unknown-role check that should be a no-op
1 parent d3c34c6 commit f99f66b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/model/channel.dart

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -212,9 +212,9 @@ mixin ChannelStore on UserStore {
212212
}) {
213213
assert(inChannel.channelPostPolicy != null);
214214
final role = selfUser.role;
215-
// We let the users with [unknown] role to send the message, then the server
216-
// will decide to accept it or not based on its actual role.
217-
if (role == UserRole.unknown) return true;
215+
216+
// (Could early-return true on [UserRole.unknown],
217+
// but pre-333 servers shouldn't be giving us an unknown role.)
218218

219219
switch (inChannel.channelPostPolicy!) {
220220
case ChannelPostPolicy.any: return true;

0 commit comments

Comments
 (0)