Skip to content

A free and open source instant messaging and VoIP chat app built for friends, groups, and communities.

TypeScript fluxerfluxerapp

fix(UseForwardDestinations): hide system user (#3038)

Jiralite944b586f2204
diff --git a/fluxer_app/src/features/app/components/dialogs/shared/UseForwardDestinations.ts b/fluxer_app/src/features/app/components/dialogs/shared/UseForwardDestinations.ts
index 695cab9a2..aa6a04f7d 100644
--- a/fluxer_app/src/features/app/components/dialogs/shared/UseForwardDestinations.ts
+++ b/fluxer_app/src/features/app/components/dialogs/shared/UseForwardDestinations.ts
@@ -41,6 +41,7 @@ import {useNow} from '@app/features/ui/state/Tick';
import type {User} from '@app/features/user/models/User';
import Users from '@app/features/user/state/Users';
import * as NicknameUtils from '@app/features/user/utils/NicknameUtils';
+import {FLUXERBOT_ID} from '@fluxer/constants/src/AppConstants';
import {ChannelTypes, Permissions} from '@fluxer/constants/src/ChannelConstants';
import {GuildNSFWLevel, GuildOperations} from '@fluxer/constants/src/GuildConstants';
import {CHANNEL_RATE_LIMIT_PER_USER_MAX} from '@fluxer/constants/src/LimitConstants';
@@ -168,6 +169,7 @@ function resolveForwardDestinationRow(destination: ForwardDestination): ForwardR
function isForwardRowValid(row: ForwardRowIdentity): boolean {
switch (row.type) {
case 'user':
+ if (row.id === FLUXERBOT_ID) return false;
return !RuntimeConfig.directMessagesDisabled || findDirectMessageChannel(row.id) != null;
case 'group_dm':
return true;