From b30610538fa91e2acf5de0585e69d9d2c10f2831 Mon Sep 17 00:00:00 2001 From: Thomas Ricouard Date: Fri, 6 Jan 2023 21:34:24 +0100 Subject: [PATCH] Fix envObject for iPad --- IceCubesApp/App/Tabs/MessagesTab.swift | 2 +- .../Sources/Conversations/List/ConversationsListView.swift | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/IceCubesApp/App/Tabs/MessagesTab.swift b/IceCubesApp/App/Tabs/MessagesTab.swift index dc17d44f..7d16277d 100644 --- a/IceCubesApp/App/Tabs/MessagesTab.swift +++ b/IceCubesApp/App/Tabs/MessagesTab.swift @@ -25,7 +25,6 @@ struct MessagesTab: View { } } .id(currentAccount.account?.id) - .environmentObject(routeurPath) } .onChange(of: $popToRootTab.wrappedValue) { popToRootTab in if popToRootTab == .messages { @@ -39,5 +38,6 @@ struct MessagesTab: View { routeurPath.client = client watcher.unreadMessagesCount = 0 } + .environmentObject(routeurPath) } } diff --git a/Packages/Conversations/Sources/Conversations/List/ConversationsListView.swift b/Packages/Conversations/Sources/Conversations/List/ConversationsListView.swift index 8f7bf8e9..dcbf38aa 100644 --- a/Packages/Conversations/Sources/Conversations/List/ConversationsListView.swift +++ b/Packages/Conversations/Sources/Conversations/List/ConversationsListView.swift @@ -51,7 +51,7 @@ public struct ConversationsListView: View { .navigationTitle("Direct Messages") .navigationBarTitleDisplayMode(.inline) .toolbar { - statusEditorToolbarItem(routeurPath: routeurPath, visibility: .direct) + StatusEditorToolbarItem(visibility: .direct) } .onChange(of: watcher.latestEvent?.id) { id in if let latestEvent = watcher.latestEvent {