Browse Source

fix(neon_notifications): Fix serialization

Signed-off-by: jld3103 <jld3103yt@gmail.com>
pull/725/head
jld3103 1 year ago
parent
commit
a3ab0dc3e8
No known key found for this signature in database
GPG Key ID: 9062417B9E8EB7B3
  1. 13
      packages/neon/neon_notifications/lib/blocs/notifications.dart

13
packages/neon/neon_notifications/lib/blocs/notifications.dart

@ -50,15 +50,16 @@ class NotificationsBloc extends InteractiveBloc
@override @override
Future refresh() async { Future refresh() async {
await RequestManager.instance.wrapNextcloud< await RequestManager.instance
List<NotificationsNotification>, .wrapNextcloud<List<NotificationsNotification>, NotificationsEndpointListNotificationsResponseApplicationJson>(
NotificationsResponse<NotificationsEndpointListNotificationsResponseApplicationJson,
NotificationsEndpointEndpointListNotificationsHeaders>>(
_account.id, _account.id,
'notifications-notifications', 'notifications-notifications',
notifications, notifications,
() async => _account.client.notifications.endpoint.listNotifications(), () async {
(final response) => response.data.ocs.data.toList(), final response = await _account.client.notifications.endpoint.listNotifications();
return response.data;
},
(final response) => response.ocs.data.toList(),
); );
} }

Loading…
Cancel
Save