From e4edbee965e0ea96943a7cf97512d09ddb964ccd Mon Sep 17 00:00:00 2001 From: Arnab Chakraborty <11457760+Rocky43007@users.noreply.github.com> Date: Sat, 28 Sep 2024 04:01:06 -0400 Subject: [PATCH] Working p2p relay backend --- .../src/components/overview/Devices.tsx | 2 +- .../src/screens/settings/info/Debug.tsx | 16 ++++++++++---- core/src/lib.rs | 2 +- .../Layout/Sidebar/sections/Devices/index.tsx | 2 +- interface/app/$libraryId/overview/index.tsx | 2 +- .../settings/client/account/Profile.tsx | 21 ++++++------------- interface/index.tsx | 1 + 7 files changed, 23 insertions(+), 23 deletions(-) diff --git a/apps/mobile/src/components/overview/Devices.tsx b/apps/mobile/src/components/overview/Devices.tsx index 9782b8fe6..a78cafe96 100644 --- a/apps/mobile/src/components/overview/Devices.tsx +++ b/apps/mobile/src/components/overview/Devices.tsx @@ -53,7 +53,7 @@ const Devices = ({ node, stats }: Props) => { })(); }, []); - const devices = useBridgeQuery(['cloud.devices.list', { access_token: accessToken.trim() }]); + const devices = useBridgeQuery(['cloud.devices.list']); // Refetch devices every 10 seconds useEffect(() => { diff --git a/apps/mobile/src/screens/settings/info/Debug.tsx b/apps/mobile/src/screens/settings/info/Debug.tsx index 74ebb4749..bc2d916b1 100644 --- a/apps/mobile/src/screens/settings/info/Debug.tsx +++ b/apps/mobile/src/screens/settings/info/Debug.tsx @@ -2,8 +2,7 @@ import { useQueryClient } from '@tanstack/react-query'; import React from 'react'; import { Text, View } from 'react-native'; import { - SyncGroupWithLibraryAndDevices, - toggleFeatureFlag, + CloudSyncGroupWithLibraryAndDevices, useBridgeMutation, useBridgeQuery, useDebugState, @@ -34,11 +33,12 @@ const DebugScreen = ({ navigation }: SettingsStackScreenProps<'Debug'>) => { }, []); const cloudBootstrap = useBridgeMutation(['cloud.bootstrap']); + const addLibraryToCloud = useLibraryMutation('cloud.libraries.create'); const requestJoinSyncGroup = useBridgeMutation('cloud.syncGroups.request_join'); const getGroup = useBridgeQuery([ 'cloud.syncGroups.get', { - pub_id: '0192123b-5d01-7341-aa9d-4a08571052ee', + pub_id: '0192376a-19ff-73a0-98ac-c4fa4043d401', with_library: true, with_devices: true, with_used_storage: true @@ -108,6 +108,13 @@ const DebugScreen = ({ navigation }: SettingsStackScreenProps<'Debug'>) => { > Cloud Bootstrap + -