|
|
|
@ -95,14 +95,15 @@ class NewsBloc extends InteractiveBloc implements NewsBlocEvents, NewsBlocStates
|
|
|
|
|
|
|
|
|
|
@override |
|
|
|
|
Future refresh() async { |
|
|
|
|
await requestManager.wrapNextcloud<List<NewsFolder>, NewsListFolders>( |
|
|
|
|
await Future.wait([ |
|
|
|
|
requestManager.wrapNextcloud<List<NewsFolder>, NewsListFolders>( |
|
|
|
|
client.id, |
|
|
|
|
'news-folders', |
|
|
|
|
folders, |
|
|
|
|
() async => client.news.listFolders(), |
|
|
|
|
(final response) => response.folders, |
|
|
|
|
); |
|
|
|
|
await requestManager.wrapNextcloud<List<NewsFeed>, NewsListFeeds>( |
|
|
|
|
), |
|
|
|
|
requestManager.wrapNextcloud<List<NewsFeed>, NewsListFeeds>( |
|
|
|
|
client.id, |
|
|
|
|
'news-feeds', |
|
|
|
|
feeds, |
|
|
|
@ -114,8 +115,9 @@ class NewsBloc extends InteractiveBloc implements NewsBlocEvents, NewsBlocStates
|
|
|
|
|
} |
|
|
|
|
return response.feeds; |
|
|
|
|
}, |
|
|
|
|
); |
|
|
|
|
await mainArticlesBloc.reload(); |
|
|
|
|
), |
|
|
|
|
mainArticlesBloc.reload(), |
|
|
|
|
]); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@override |
|
|
|
|