From a3ab0dc3e888cc0214c4fbb1e523d8ad3d554fd5 Mon Sep 17 00:00:00 2001 From: jld3103 Date: Thu, 7 Sep 2023 10:29:08 +0200 Subject: [PATCH] fix(neon_notifications): Fix serialization Signed-off-by: jld3103 --- .../neon_notifications/lib/blocs/notifications.dart | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/packages/neon/neon_notifications/lib/blocs/notifications.dart b/packages/neon/neon_notifications/lib/blocs/notifications.dart index ef9afa44..e80a4433 100644 --- a/packages/neon/neon_notifications/lib/blocs/notifications.dart +++ b/packages/neon/neon_notifications/lib/blocs/notifications.dart @@ -50,15 +50,16 @@ class NotificationsBloc extends InteractiveBloc @override Future refresh() async { - await RequestManager.instance.wrapNextcloud< - List, - NotificationsResponse>( + await RequestManager.instance + .wrapNextcloud, NotificationsEndpointListNotificationsResponseApplicationJson>( _account.id, 'notifications-notifications', notifications, - () async => _account.client.notifications.endpoint.listNotifications(), - (final response) => response.data.ocs.data.toList(), + () async { + final response = await _account.client.notifications.endpoint.listNotifications(); + return response.data; + }, + (final response) => response.ocs.data.toList(), ); }