diff --git a/src/RawRabbit.Operations.Get/Middleware/AckableResultMiddleware.cs b/src/RawRabbit.Operations.Get/Middleware/AckableResultMiddleware.cs index ec7359e8..928e294c 100644 --- a/src/RawRabbit.Operations.Get/Middleware/AckableResultMiddleware.cs +++ b/src/RawRabbit.Operations.Get/Middleware/AckableResultMiddleware.cs @@ -33,7 +33,7 @@ public class AckableResultMiddleware : Pipe.Middleware.Middleware public AckableResultMiddleware(AckableResultOptions options = null) { GetResultFunc = options?.ContentFunc; - ChannelFunc = options?.ChannelFunc ?? (context => context.GetTransientChannel()); + ChannelFunc = options?.ChannelFunc ?? (context => context.GetChannel()); PostExecutionAction = options?.PostExecutionAction; DeliveryTagFunc = options?.DeliveryTagFunc; } diff --git a/src/RawRabbit.Operations.Get/Middleware/BasicGetMiddleware.cs b/src/RawRabbit.Operations.Get/Middleware/BasicGetMiddleware.cs index 852db5f2..702c7496 100644 --- a/src/RawRabbit.Operations.Get/Middleware/BasicGetMiddleware.cs +++ b/src/RawRabbit.Operations.Get/Middleware/BasicGetMiddleware.cs @@ -23,7 +23,7 @@ public class BasicGetMiddleware : Pipe.Middleware.Middleware public BasicGetMiddleware(BasicGetOptions options = null) { - ChannelFunc = options?.ChannelFunc ?? (context => context.GetTransientChannel()); + ChannelFunc = options?.ChannelFunc ?? (context => context.GetChannel()); QueueNameFunc = options?.QueueNameFunc ?? (context => context.GetGetConfiguration()?.QueueName); AutoAckFunc = options?.AutoAckFunc ?? (context => context.GetGetConfiguration()?.AutoAck ?? false); PostExecutionAction = options?.PostExecutionAction;