mirror of
https://github.com/streetwriters/notesnook-sync-server.git
synced 2026-10-02 02:59:33 +02:00
api: handle subscription fetch errors
This commit is contained in:
1 parent
72e825a12c
commit
2b6a58ff04
2 files changed
+2
-2
No files matched your search
@@ -118,7 +118,7 @@ namespace Notesnook.API.Services
|
||||
else
|
||||
{
|
||||
var subscriptionService = await WampServers.SubscriptionServer.GetServiceAsync<IUserSubscriptionService>(SubscriptionServerTopics.UserSubscriptionServiceTopic);
|
||||
subscription = await subscriptionService.GetUserSubscriptionAsync(Clients.Notesnook.Id, userId);
|
||||
subscription = await subscriptionService.GetUserSubscriptionAsync(Clients.Notesnook.Id, userId) ?? throw new Exception("User subscription not found.");
|
||||
}
|
||||
|
||||
var userSettings = await Repositories.UsersSettings.FindOneAsync((u) => u.UserId == user.UserId) ?? throw new Exception("User settings not found.");
|
||||
|
||||
Reference in new issue
Block a user