feat(templates): add localized push templates and actions
Share template keys across email and push with independent editors and revisions. Render localized actions and preserve version-one delivery. Ref: IT-1627
This commit is contained in:
@@ -14,6 +14,11 @@ public sealed class SendPushConsumer(
|
||||
|
||||
protected override bool TryValidateMessage(SendPushMessage message, RabbitMqMessageContext context, out string? validationError)
|
||||
{
|
||||
if (message?.Data is { } data && !PushMessageValidator.IsSupportedVersion(data.Version))
|
||||
{
|
||||
validationError = "Unsupported push payload version. Supported versions are 1 and 2.";
|
||||
return false;
|
||||
}
|
||||
bool valid = SendPushDeliveryValidator.IsValid(message, context);
|
||||
validationError = valid ? null : "Invalid push envelope.";
|
||||
return valid;
|
||||
|
||||
Reference in New Issue
Block a user