pardahlman / RawRabbit

A modern .NET framework for communication over RabbitMq
MIT License
746 stars 144 forks source link

Using BasicGetOperation with empty Queue throws a Null exception #323

Closed Ankurkh1 closed 6 years ago

Ankurkh1 commented 6 years ago

https://github.com/pardahlman/RawRabbit/blob/e4b6081ee3d057bfaa4b634d92e5a23a7d0de6c1/src/RawRabbit.Operations.Get/GetOperation.cs#L22

Line 22 should test for nulls. Like how it does for GetOfTOperation DeliveryTagFunc = context => context.GetBasicGetResult()?.DeliveryTag ?? 0,

pardahlman commented 6 years ago

You are right - feel free to submit a PR for this 👍