File tree Expand file tree Collapse file tree
IceCubesApp/App/Tabs/Timeline
Packages/Notifications/Sources/Notifications Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -60,13 +60,13 @@ struct TimelineTab: View {
6060 timeline = . trending
6161 }
6262 }
63- Task {
64- await currentAccount. fetchLists ( )
65- }
6663 if !client. isAuth {
6764 routerPath. presentedSheet = . addAccount
6865 }
6966 }
67+ . task {
68+ await currentAccount. fetchLists ( )
69+ }
7070 . onChange ( of: client. isAuth) {
7171 resetTimelineFilter ( )
7272 }
Original file line number Diff line number Diff line change @@ -106,7 +106,7 @@ public struct NotificationsListView: View {
106106 . scrollContentBackground( . hidden)
107107 . background ( theme. primaryBackgroundColor)
108108 #endif
109- . onAppear {
109+ . task {
110110 viewModel. client = client
111111 viewModel. currentAccount = account
112112 if let lockedType {
@@ -117,10 +117,8 @@ public struct NotificationsListView: View {
117117 } else {
118118 viewModel. loadSelectedType ( )
119119 }
120- Task {
121- await viewModel. fetchNotifications ( viewModel. selectedType)
122- await viewModel. fetchPolicy ( )
123- }
120+ await viewModel. fetchNotifications ( viewModel. selectedType)
121+ await viewModel. fetchPolicy ( )
124122 }
125123 . refreshable {
126124 SoundEffectManager . shared. playSound ( . pull)
You can’t perform that action at this time.
0 commit comments