Skip to content

Commit

Permalink
MessageBus pusblish effect 2 (#263)
Browse files Browse the repository at this point in the history
  • Loading branch information
oncicaradupopovici authored Oct 3, 2023
1 parent 9298402 commit b280503
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Messaging/NBB.Messaging.Effects/MessageBus.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@
// This source code is licensed under the MIT license.

using NBB.Core.Effects;

using NBB.Messaging.Abstractions;

namespace NBB.Messaging.Effects
{
public static class MessageBus
{
public static Effect<Unit> Publish(object message) => Effect.Of<PublishMessage.SideEffect, Unit>(new PublishMessage.SideEffect(message));
public static Effect<Unit> Publish(object message, MessagingPublisherOptions options = null) => Effect.Of<PublishMessage.SideEffect, Unit>(new PublishMessage.SideEffect(message, options));
}
}

0 comments on commit b280503

Please sign in to comment.