From 3704d2569ccb7965c712f76358f26cf98d675dee Mon Sep 17 00:00:00 2001 From: Matt Grogan Date: Mon, 25 Sep 2023 06:13:44 -0500 Subject: [PATCH] Remove redundant rules code (#4430) --- backend/canisters/community/api/can.did | 3 - .../src/queries/selected_channel_initial.rs | 4 +- .../api/src/queries/selected_initial.rs | 4 +- .../api/src/queries/selected_updates_v2.rs | 6 +- .../src/queries/selected_channel_initial.rs | 1 - .../impl/src/queries/selected_initial.rs | 1 - .../impl/src/queries/selected_updates.rs | 4 -- backend/canisters/group/api/can.did | 1 - .../group/api/src/queries/selected_initial.rs | 4 +- .../impl/src/queries/selected_initial.rs | 1 - .../user_index/impl/src/queries/users.rs | 10 --- .../src/communities/send_message_tests.rs | 63 ++++++++++--------- backend/libraries/group_chat_core/src/lib.rs | 3 +- backend/libraries/types/can.did | 1 - backend/libraries/types/src/chat_summary.rs | 4 +- backend/libraries/types/src/group_roles.rs | 6 -- backend/libraries/types/src/user_summary.rs | 14 ----- .../src/services/community/candid/idl.js | 4 -- .../src/services/community/candid/types.d.ts | 4 -- .../src/services/group/candid/idl.js | 2 - .../src/services/group/candid/types.d.ts | 2 - .../src/services/groupIndex/candid/types.d.ts | 1 - .../services/localUserIndex/candid/types.d.ts | 1 - .../services/notifications/candid/types.d.ts | 1 - .../src/services/online/candid/types.d.ts | 1 - .../src/services/registry/candid/types.d.ts | 1 - .../services/storageBucket/candid/types.d.ts | 1 - .../services/storageIndex/candid/types.d.ts | 1 - .../src/services/userIndex/candid/types.d.ts | 1 - 29 files changed, 40 insertions(+), 110 deletions(-) diff --git a/backend/canisters/community/api/can.did b/backend/canisters/community/api/can.did index 1a1ef56e64..bf63ae74e0 100644 --- a/backend/canisters/community/api/can.did +++ b/backend/canisters/community/api/can.did @@ -132,7 +132,6 @@ type SelectedChannelInitialResponse = variant { blocked_users : vec UserId; invited_users : vec UserId; pinned_messages : vec MessageIndex; - rules : Rules; chat_rules : VersionedRules; }; PrivateCommunity; @@ -176,7 +175,6 @@ type SelectedInitialSuccess = record { members : vec CommunityMember; blocked_users : vec UserId; invited_users : vec UserId; - rules : Rules; chat_rules : VersionedRules; user_groups : vec UserGroupDetails; }; @@ -205,7 +203,6 @@ type SelectedUpdatesSuccess = record { blocked_users_added : vec UserId; blocked_users_removed : vec UserId; invited_users : opt vec UserId; - rules : opt Rules; chat_rules : opt VersionedRules; user_groups : vec UserGroupDetails; user_groups_deleted : vec nat32; diff --git a/backend/canisters/community/api/src/queries/selected_channel_initial.rs b/backend/canisters/community/api/src/queries/selected_channel_initial.rs index 295f4ca145..395959a81d 100644 --- a/backend/canisters/community/api/src/queries/selected_channel_initial.rs +++ b/backend/canisters/community/api/src/queries/selected_channel_initial.rs @@ -1,6 +1,6 @@ use candid::CandidType; use serde::{Deserialize, Serialize}; -use types::{ChannelId, EventIndex, GroupMember, MessageIndex, Rules, TimestampMillis, UserId, VersionedRules}; +use types::{ChannelId, EventIndex, GroupMember, MessageIndex, TimestampMillis, UserId, VersionedRules}; #[derive(CandidType, Serialize, Deserialize, Debug)] pub struct Args { @@ -23,7 +23,5 @@ pub struct SuccessResult { pub blocked_users: Vec, pub invited_users: Vec, pub pinned_messages: Vec, - // TODO: remove this field once the website is using `chat_rules` instead - pub rules: Rules, pub chat_rules: VersionedRules, } diff --git a/backend/canisters/community/api/src/queries/selected_initial.rs b/backend/canisters/community/api/src/queries/selected_initial.rs index c4f35e1176..90c434454b 100644 --- a/backend/canisters/community/api/src/queries/selected_initial.rs +++ b/backend/canisters/community/api/src/queries/selected_initial.rs @@ -1,6 +1,6 @@ use candid::CandidType; use serde::{Deserialize, Serialize}; -use types::{CommunityMember, EventIndex, Rules, TimestampMillis, UserGroupDetails, UserId, VersionedRules}; +use types::{CommunityMember, EventIndex, TimestampMillis, UserGroupDetails, UserId, VersionedRules}; #[derive(CandidType, Serialize, Deserialize, Debug)] pub struct Args { @@ -20,8 +20,6 @@ pub struct SuccessResult { pub members: Vec, pub blocked_users: Vec, pub invited_users: Vec, - // TODO: remove this field once the website is using `chat_rules` instead - pub rules: Rules, pub chat_rules: VersionedRules, pub user_groups: Vec, } diff --git a/backend/canisters/community/api/src/queries/selected_updates_v2.rs b/backend/canisters/community/api/src/queries/selected_updates_v2.rs index 0dd9fb02d2..0c8763b664 100644 --- a/backend/canisters/community/api/src/queries/selected_updates_v2.rs +++ b/backend/canisters/community/api/src/queries/selected_updates_v2.rs @@ -1,6 +1,6 @@ use candid::CandidType; use serde::{Deserialize, Serialize}; -use types::{CommunityMember, Rules, TimestampMillis, UserGroupDetails, UserId, VersionedRules}; +use types::{CommunityMember, TimestampMillis, UserGroupDetails, UserId, VersionedRules}; #[derive(CandidType, Serialize, Deserialize, Debug)] pub struct Args { @@ -24,8 +24,6 @@ pub struct SuccessResult { pub blocked_users_added: Vec, pub blocked_users_removed: Vec, pub invited_users: Option>, - // TODO: remove this field once the website is using `chat_rules` instead - pub rules: Option, pub chat_rules: Option, pub user_groups: Vec, pub user_groups_deleted: Vec, @@ -38,6 +36,6 @@ impl SuccessResult { || !self.blocked_users_added.is_empty() || !self.blocked_users_removed.is_empty() || self.invited_users.is_some() - || self.rules.is_some() + || self.chat_rules.is_some() } } diff --git a/backend/canisters/community/impl/src/queries/selected_channel_initial.rs b/backend/canisters/community/impl/src/queries/selected_channel_initial.rs index 0218ac9d75..30b49c2b80 100644 --- a/backend/canisters/community/impl/src/queries/selected_channel_initial.rs +++ b/backend/canisters/community/impl/src/queries/selected_channel_initial.rs @@ -31,7 +31,6 @@ fn selected_channel_initial_impl(args: Args, state: &RuntimeState) -> Response { blocked_users: chat.members.blocked(), invited_users: chat.invited_users.users(), pinned_messages: chat.pinned_messages.clone(), - rules: chat.rules.clone().into(), chat_rules: chat.rules.clone().into(), }) } else { diff --git a/backend/canisters/community/impl/src/queries/selected_initial.rs b/backend/canisters/community/impl/src/queries/selected_initial.rs index 08f689f683..39e770047b 100644 --- a/backend/canisters/community/impl/src/queries/selected_initial.rs +++ b/backend/canisters/community/impl/src/queries/selected_initial.rs @@ -23,7 +23,6 @@ fn selected_initial_impl(args: Args, state: &RuntimeState) -> Response { members: members.iter().map(|m| m.into()).collect(), blocked_users: members.blocked(), invited_users: state.data.invited_users.users(), - rules: state.data.rules.clone().into(), chat_rules: state.data.rules.clone().into(), user_groups: state.data.members.iter_user_groups().map(|u| u.into()).collect(), }) diff --git a/backend/canisters/community/impl/src/queries/selected_updates.rs b/backend/canisters/community/impl/src/queries/selected_updates.rs index 2c36af63f2..d939bcf29a 100644 --- a/backend/canisters/community/impl/src/queries/selected_updates.rs +++ b/backend/canisters/community/impl/src/queries/selected_updates.rs @@ -58,7 +58,6 @@ fn selected_updates_impl(args: Args, state: &RuntimeState) -> Response { blocked_users_added: vec![], blocked_users_removed: vec![], invited_users, - rules: None, chat_rules: None, user_groups: data .members @@ -105,9 +104,6 @@ fn selected_updates_impl(args: Args, state: &RuntimeState) -> Response { } } CommunityEventInternal::RulesChanged(_) => { - if result.rules.is_none() { - result.rules = Some(data.rules.clone().into()); - } if result.chat_rules.is_none() { result.chat_rules = Some(data.rules.clone().into()); } diff --git a/backend/canisters/group/api/can.did b/backend/canisters/group/api/can.did index 247ae919a2..64dc5f6352 100644 --- a/backend/canisters/group/api/can.did +++ b/backend/canisters/group/api/can.did @@ -358,7 +358,6 @@ type SelectedInitialSuccess = record { blocked_users : vec UserId; invited_users : vec UserId; pinned_messages : vec MessageIndex; - rules : Rules; chat_rules : VersionedRules; }; diff --git a/backend/canisters/group/api/src/queries/selected_initial.rs b/backend/canisters/group/api/src/queries/selected_initial.rs index 3b9a5d400b..3c7969f498 100644 --- a/backend/canisters/group/api/src/queries/selected_initial.rs +++ b/backend/canisters/group/api/src/queries/selected_initial.rs @@ -1,6 +1,6 @@ use candid::CandidType; use serde::{Deserialize, Serialize}; -use types::{Empty, EventIndex, GroupMember, MessageIndex, Rules, TimestampMillis, UserId, VersionedRules}; +use types::{Empty, EventIndex, GroupMember, MessageIndex, TimestampMillis, UserId, VersionedRules}; pub type Args = Empty; @@ -18,7 +18,5 @@ pub struct SuccessResult { pub blocked_users: Vec, pub invited_users: Vec, pub pinned_messages: Vec, - // TODO: remove this field once the website is using `chat_rules` instead - pub rules: Rules, pub chat_rules: VersionedRules, } diff --git a/backend/canisters/group/impl/src/queries/selected_initial.rs b/backend/canisters/group/impl/src/queries/selected_initial.rs index 8a111fb25c..e6215ca762 100644 --- a/backend/canisters/group/impl/src/queries/selected_initial.rs +++ b/backend/canisters/group/impl/src/queries/selected_initial.rs @@ -26,7 +26,6 @@ fn selected_initial_impl(state: &RuntimeState) -> Response { .filter(|&m| *m >= min_visible_message_index) .copied() .collect(), - rules: chat.rules.clone().into(), chat_rules: chat.rules.clone().into(), }) } else { diff --git a/backend/canisters/user_index/impl/src/queries/users.rs b/backend/canisters/user_index/impl/src/queries/users.rs index b9f471521c..8e6e479aa2 100644 --- a/backend/canisters/user_index/impl/src/queries/users.rs +++ b/backend/canisters/user_index/impl/src/queries/users.rs @@ -2,16 +2,6 @@ use crate::{read_state, RuntimeState}; use ic_cdk_macros::query; use user_index_canister::users_v2::{Response::*, *}; -#[query] -fn users(args: user_index_canister::users::Args) -> user_index_canister::users::Response { - let Success(response) = read_state(|state| users_impl(args, state)); - - user_index_canister::users::Response::Success(user_index_canister::users::Result { - users: response.users.into_iter().map(|summary| summary.into()).collect(), - timestamp: response.timestamp, - }) -} - #[query] fn users_v2(args: Args) -> Response { read_state(|state| users_impl(args, state)) diff --git a/backend/integration_tests/src/communities/send_message_tests.rs b/backend/integration_tests/src/communities/send_message_tests.rs index b487324db2..d030d9275b 100644 --- a/backend/integration_tests/src/communities/send_message_tests.rs +++ b/backend/integration_tests/src/communities/send_message_tests.rs @@ -123,12 +123,14 @@ fn send_message_with_community_rules_not_accepted_fails() { set_community_rules(env, &user1, community_id, "No heavy petting".to_string()); - let _response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, None); + let response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, None); - // TODO: Re-enable check once RulesNotAccepted is returned - // if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { - // panic!("{response:?}"); - // } + if !matches!( + response, + community_canister::send_message::Response::CommunityRulesNotAccepted + ) { + panic!("{response:?}"); + } } #[test] @@ -151,12 +153,11 @@ fn send_message_with_channel_rules_not_accepted_fails() { set_channel_rules(env, &user1, community_id, channel_id, "No running".to_string()); - let _response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, None); + let response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, None); - // TODO: Re-enable check once RulesNotAccepted is returned - // if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { - // panic!("{response:?}"); - // } + if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { + panic!("{response:?}"); + } } #[test] @@ -234,12 +235,11 @@ fn send_message_with_community_rules_but_not_channel_rules_accepted_fails() { set_community_rules(env, &user1, community_id, "No heavy petting".to_string()); set_channel_rules(env, &user1, community_id, channel_id, "No running".to_string()); - let _response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, Some(Version::from(1)), None); + let response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, Some(Version::from(1)), None); - // TODO: Re-enable check once RulesNotAccepted is returned - // if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { - // panic!("{response:?}"); - // } + if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { + panic!("{response:?}"); + } } #[test] @@ -263,12 +263,14 @@ fn send_message_with_channel_rules_but_not_community_rules_accepted_fails() { set_community_rules(env, &user1, community_id, "No heavy petting".to_string()); set_channel_rules(env, &user1, community_id, channel_id, "No running".to_string()); - let _response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, Some(Version::from(1))); + let response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, Some(Version::from(1))); - // TODO: Re-enable check once RulesNotAccepted is returned - // if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { - // panic!("{response:?}"); - // } + if !matches!( + response, + community_canister::send_message::Response::CommunityRulesNotAccepted + ) { + panic!("{response:?}"); + } } #[test] @@ -364,7 +366,7 @@ fn send_message_with_old_community_rules_accepted_fails() { set_community_rules(env, &user1, community_id, "No heavy petting".to_string()); set_community_rules(env, &user1, community_id, "No heavy petting or pets".to_string()); - let _response = send_dummy_message_with_rules( + let response = send_dummy_message_with_rules( env, &user2, community_id, @@ -373,10 +375,12 @@ fn send_message_with_old_community_rules_accepted_fails() { Some(Version::from(1)), ); - // TODO: Re-enable check once RulesNotAccepted is returned - // if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { - // panic!("{response:?}"); - // } + if !matches!( + response, + community_canister::send_message::Response::CommunityRulesNotAccepted + ) { + panic!("{response:?}"); + } } #[test] @@ -400,12 +404,11 @@ fn send_message_with_old_channel_rules_accepted_fails() { set_channel_rules(env, &user1, community_id, channel_id, "No running".to_string()); set_channel_rules(env, &user1, community_id, channel_id, "No running or jumping".to_string()); - let _response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, Some(Version::from(1))); + let response = send_dummy_message_with_rules(env, &user2, community_id, channel_id, None, Some(Version::from(1))); - // TODO: Re-enable check once RulesNotAccepted is returned - // if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { - // panic!("{response:?}"); - // } + if !matches!(response, community_canister::send_message::Response::RulesNotAccepted) { + panic!("{response:?}"); + } } #[test] diff --git a/backend/libraries/group_chat_core/src/lib.rs b/backend/libraries/group_chat_core/src/lib.rs index 51461732f5..3194f01c8a 100644 --- a/backend/libraries/group_chat_core/src/lib.rs +++ b/backend/libraries/group_chat_core/src/lib.rs @@ -378,8 +378,7 @@ impl GroupChatCore { } } ChatEventInternal::GroupRulesChanged(_) => { - if result.rules.is_none() { - result.rules = Some(self.rules.clone().into()); + if result.chat_rules.is_none() { result.chat_rules = Some(self.rules.clone().into()); } } diff --git a/backend/libraries/types/can.did b/backend/libraries/types/can.did index 696d1b2e83..f8753904ae 100644 --- a/backend/libraries/types/can.did +++ b/backend/libraries/types/can.did @@ -478,7 +478,6 @@ type SelectedGroupUpdates = record { invited_users : opt vec UserId; pinned_messages_added : vec MessageIndex; pinned_messages_removed : vec MessageIndex; - rules : opt Rules; chat_rules : opt VersionedRules; }; diff --git a/backend/libraries/types/src/chat_summary.rs b/backend/libraries/types/src/chat_summary.rs index 122e97fd73..e21b246623 100644 --- a/backend/libraries/types/src/chat_summary.rs +++ b/backend/libraries/types/src/chat_summary.rs @@ -245,8 +245,6 @@ pub struct SelectedGroupUpdates { pub invited_users: Option>, pub pinned_messages_added: Vec, pub pinned_messages_removed: Vec, - // TODO: remove this field once the website is using `chat_rules` instead - pub rules: Option, pub chat_rules: Option, } @@ -259,7 +257,7 @@ impl SelectedGroupUpdates { || self.invited_users.is_some() || !self.pinned_messages_added.is_empty() || !self.pinned_messages_removed.is_empty() - || self.rules.is_some() + || self.chat_rules.is_some() } } diff --git a/backend/libraries/types/src/group_roles.rs b/backend/libraries/types/src/group_roles.rs index f8fac2c412..8856b50a5e 100644 --- a/backend/libraries/types/src/group_roles.rs +++ b/backend/libraries/types/src/group_roles.rs @@ -29,8 +29,6 @@ pub struct GroupPermissions { pub send_messages: GroupPermissionRole, pub react_to_messages: GroupPermissionRole, pub reply_in_thread: GroupPermissionRole, - // TODO: Remove this field once communities and groups have been released - #[serde(default = "group_permission_role_admin")] pub mention_all_members: GroupPermissionRole, } @@ -87,7 +85,3 @@ pub enum GroupPermissionRole { fn group_permission_role_owner() -> GroupPermissionRole { GroupPermissionRole::Owner } - -fn group_permission_role_admin() -> GroupPermissionRole { - GroupPermissionRole::Admins -} diff --git a/backend/libraries/types/src/user_summary.rs b/backend/libraries/types/src/user_summary.rs index e92e84f4d0..2cbe4e9e51 100644 --- a/backend/libraries/types/src/user_summary.rs +++ b/backend/libraries/types/src/user_summary.rs @@ -22,17 +22,3 @@ pub struct PartialUserSummary { pub suspended: bool, pub diamond_member: bool, } - -// TODO: Remove this once the website is using users_v2 -impl From for PartialUserSummary { - fn from(summary: UserSummary) -> Self { - PartialUserSummary { - user_id: summary.user_id, - username: Some(summary.username), - avatar_id: summary.avatar_id, - is_bot: summary.is_bot, - suspended: summary.suspended, - diamond_member: summary.diamond_member, - } - } -} diff --git a/frontend/openchat-agent/src/services/community/candid/idl.js b/frontend/openchat-agent/src/services/community/candid/idl.js index 2d6c4e175f..4e0c68e124 100644 --- a/frontend/openchat-agent/src/services/community/candid/idl.js +++ b/frontend/openchat-agent/src/services/community/candid/idl.js @@ -1238,7 +1238,6 @@ export const idlFactory = ({ IDL }) => { 'timestamp' : TimestampMillis, 'pinned_messages' : IDL.Vec(MessageIndex), 'latest_event_index' : EventIndex, - 'rules' : Rules, }), 'PrivateCommunity' : IDL.Null, 'PrivateChannel' : IDL.Null, @@ -1257,7 +1256,6 @@ export const idlFactory = ({ IDL }) => { 'members_removed' : IDL.Vec(UserId), 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : IDL.Opt(Rules), 'blocked_users_added' : IDL.Vec(UserId), }); const SelectedChannelUpdatesResponse = IDL.Variant({ @@ -1296,7 +1294,6 @@ export const idlFactory = ({ IDL }) => { 'user_groups' : IDL.Vec(UserGroupDetails), 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : Rules, }); const SelectedInitialResponse = IDL.Variant({ 'Success' : SelectedInitialSuccess, @@ -1315,7 +1312,6 @@ export const idlFactory = ({ IDL }) => { 'user_groups' : IDL.Vec(UserGroupDetails), 'members_removed' : IDL.Vec(UserId), 'timestamp' : TimestampMillis, - 'rules' : IDL.Opt(Rules), 'blocked_users_added' : IDL.Vec(UserId), }); const SelectedUpdatesResponse = IDL.Variant({ diff --git a/frontend/openchat-agent/src/services/community/candid/types.d.ts b/frontend/openchat-agent/src/services/community/candid/types.d.ts index 3a544982a5..fc9b97e1b8 100644 --- a/frontend/openchat-agent/src/services/community/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/community/candid/types.d.ts @@ -1489,7 +1489,6 @@ export type SelectedChannelInitialResponse = { 'ChannelNotFound' : null } | 'timestamp' : TimestampMillis, 'pinned_messages' : Uint32Array | number[], 'latest_event_index' : EventIndex, - 'rules' : Rules, } } | { 'PrivateCommunity' : null } | @@ -1518,7 +1517,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SelectedInitialArgs { 'invite_code' : [] | [bigint] } @@ -1532,7 +1530,6 @@ export interface SelectedInitialSuccess { 'user_groups' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : Rules, } export interface SelectedUpdatesArgs { 'updates_since' : TimestampMillis, @@ -1550,7 +1547,6 @@ export interface SelectedUpdatesSuccess { 'user_groups' : Array, 'members_removed' : Array, 'timestamp' : TimestampMillis, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export type SelectedUpdatesV2Response = { 'Success' : SelectedUpdatesSuccess } | diff --git a/frontend/openchat-agent/src/services/group/candid/idl.js b/frontend/openchat-agent/src/services/group/candid/idl.js index 951d843325..ddeb036068 100644 --- a/frontend/openchat-agent/src/services/group/candid/idl.js +++ b/frontend/openchat-agent/src/services/group/candid/idl.js @@ -933,7 +933,6 @@ export const idlFactory = ({ IDL }) => { 'timestamp' : TimestampMillis, 'pinned_messages' : IDL.Vec(MessageIndex), 'latest_event_index' : EventIndex, - 'rules' : Rules, }); const SelectedInitialResponse = IDL.Variant({ 'CallerNotInGroup' : IDL.Null, @@ -952,7 +951,6 @@ export const idlFactory = ({ IDL }) => { 'members_removed' : IDL.Vec(UserId), 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : IDL.Opt(Rules), 'blocked_users_added' : IDL.Vec(UserId), }); const SelectedUpdatesV2Response = IDL.Variant({ diff --git a/frontend/openchat-agent/src/services/group/candid/types.d.ts b/frontend/openchat-agent/src/services/group/candid/types.d.ts index 7625f35da8..62c059031b 100644 --- a/frontend/openchat-agent/src/services/group/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/group/candid/types.d.ts @@ -1333,7 +1333,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export type SelectedInitialArgs = {}; @@ -1347,7 +1346,6 @@ export interface SelectedInitialSuccess { 'timestamp' : TimestampMillis, 'pinned_messages' : Uint32Array | number[], 'latest_event_index' : EventIndex, - 'rules' : Rules, } export interface SelectedUpdatesV2Args { 'updates_since' : TimestampMillis } export type SelectedUpdatesV2Response = { 'CallerNotInGroup' : null } | diff --git a/frontend/openchat-agent/src/services/groupIndex/candid/types.d.ts b/frontend/openchat-agent/src/services/groupIndex/candid/types.d.ts index 8c708c18cc..6d9ad6cb85 100644 --- a/frontend/openchat-agent/src/services/groupIndex/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/groupIndex/candid/types.d.ts @@ -1210,7 +1210,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SetCommunityModerationFlagsArgs { diff --git a/frontend/openchat-agent/src/services/localUserIndex/candid/types.d.ts b/frontend/openchat-agent/src/services/localUserIndex/candid/types.d.ts index 211e99a67c..9c2a4fe863 100644 --- a/frontend/openchat-agent/src/services/localUserIndex/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/localUserIndex/candid/types.d.ts @@ -1207,7 +1207,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SnsNeuronGate { diff --git a/frontend/openchat-agent/src/services/notifications/candid/types.d.ts b/frontend/openchat-agent/src/services/notifications/candid/types.d.ts index a655c2bdb5..72db7c1734 100644 --- a/frontend/openchat-agent/src/services/notifications/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/notifications/candid/types.d.ts @@ -1082,7 +1082,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SnsNeuronGate { diff --git a/frontend/openchat-agent/src/services/online/candid/types.d.ts b/frontend/openchat-agent/src/services/online/candid/types.d.ts index 5ef8f71c38..3ff90213c4 100644 --- a/frontend/openchat-agent/src/services/online/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/online/candid/types.d.ts @@ -1085,7 +1085,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SnsNeuronGate { diff --git a/frontend/openchat-agent/src/services/registry/candid/types.d.ts b/frontend/openchat-agent/src/services/registry/candid/types.d.ts index 0ef070596d..695885733c 100644 --- a/frontend/openchat-agent/src/services/registry/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/registry/candid/types.d.ts @@ -1075,7 +1075,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SnsNeuronGate { diff --git a/frontend/openchat-agent/src/services/storageBucket/candid/types.d.ts b/frontend/openchat-agent/src/services/storageBucket/candid/types.d.ts index 5f73dd91f5..260e72d5e2 100644 --- a/frontend/openchat-agent/src/services/storageBucket/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/storageBucket/candid/types.d.ts @@ -1105,7 +1105,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SnsNeuronGate { diff --git a/frontend/openchat-agent/src/services/storageIndex/candid/types.d.ts b/frontend/openchat-agent/src/services/storageIndex/candid/types.d.ts index c793cebc86..597a3c033e 100644 --- a/frontend/openchat-agent/src/services/storageIndex/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/storageIndex/candid/types.d.ts @@ -1115,7 +1115,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SetBucketFullArgs { 'full' : boolean, 'bucket' : CanisterId } diff --git a/frontend/openchat-agent/src/services/userIndex/candid/types.d.ts b/frontend/openchat-agent/src/services/userIndex/candid/types.d.ts index 132b920764..9170c59be1 100644 --- a/frontend/openchat-agent/src/services/userIndex/candid/types.d.ts +++ b/frontend/openchat-agent/src/services/userIndex/candid/types.d.ts @@ -1193,7 +1193,6 @@ export interface SelectedGroupUpdates { 'members_removed' : Array, 'timestamp' : TimestampMillis, 'latest_event_index' : EventIndex, - 'rules' : [] | [Rules], 'blocked_users_added' : Array, } export interface SetDisplayNameArgs { 'display_name' : [] | [string] }