mirror of
https://github.com/bitwarden/server.git
synced 2026-02-15 21:33:16 +08:00
PM-15084: Consistent notification center push type names.
Renamed PushType's `SyncNotification` to `Notification`, since the push type payload does not require, is not dependent on the sync mechanism.
This commit is contained in:
@@ -216,17 +216,17 @@ public class RelayPushNotificationService : BaseIdentityClientService, IPushNoti
|
||||
|
||||
if (notification.Global)
|
||||
{
|
||||
await SendPayloadToInstallationAsync(PushType.SyncNotification, message, true,
|
||||
await SendPayloadToInstallationAsync(PushType.Notification, message, true,
|
||||
notification.ClientType);
|
||||
}
|
||||
else if (notification.UserId.HasValue)
|
||||
{
|
||||
await SendPayloadToUserAsync(notification.UserId.Value, PushType.SyncNotification, message, true,
|
||||
await SendPayloadToUserAsync(notification.UserId.Value, PushType.Notification, message, true,
|
||||
notification.ClientType);
|
||||
}
|
||||
else if (notification.OrganizationId.HasValue)
|
||||
{
|
||||
await SendPayloadToOrganizationAsync(notification.OrganizationId.Value, PushType.SyncNotification, message,
|
||||
await SendPayloadToOrganizationAsync(notification.OrganizationId.Value, PushType.Notification, message,
|
||||
true, notification.ClientType);
|
||||
}
|
||||
}
|
||||
@@ -252,17 +252,17 @@ public class RelayPushNotificationService : BaseIdentityClientService, IPushNoti
|
||||
|
||||
if (notification.Global)
|
||||
{
|
||||
await SendPayloadToInstallationAsync(PushType.SyncNotificationStatus, message, true,
|
||||
await SendPayloadToInstallationAsync(PushType.NotificationStatus, message, true,
|
||||
notification.ClientType);
|
||||
}
|
||||
else if (notification.UserId.HasValue)
|
||||
{
|
||||
await SendPayloadToUserAsync(notification.UserId.Value, PushType.SyncNotificationStatus, message, true,
|
||||
await SendPayloadToUserAsync(notification.UserId.Value, PushType.NotificationStatus, message, true,
|
||||
notification.ClientType);
|
||||
}
|
||||
else if (notification.OrganizationId.HasValue)
|
||||
{
|
||||
await SendPayloadToOrganizationAsync(notification.OrganizationId.Value, PushType.SyncNotificationStatus,
|
||||
await SendPayloadToOrganizationAsync(notification.OrganizationId.Value, PushType.NotificationStatus,
|
||||
message, true, notification.ClientType);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user