Reddit.NET icon indicating copy to clipboard operation
Reddit.NET copied to clipboard

fix: initialize modmail cache

Open kyleratti opened this issue 4 years ago • 2 comments

This resolves a null reference exception I was receiving when trying to monitor unread modmail on 1.5.0. It looks like this is a bug from the code introduced as part of #117 - all other controllers initialize UseCache except Modmail.

System.NullReferenceException
  HResult=0x80004003
  Message=Object reference not set to an instance of an object.
  Source=Reddit.NET
  StackTrace:
   at Reddit.Controllers.Internal.Monitors.InitMonitoringCache(Boolean useCache, String type)

kyleratti avatar Jun 29 '21 03:06 kyleratti

Why was this closed? Did you find a problem with the commit? If I'm going to include this in the 1.6 release it'll need to remain open so I won't miss it.

sirkris avatar Apr 26 '22 20:04 sirkris

Hi there,

I was just pruning my stale issues and PRs.

I never heard anything from this PR and depended heavily on this working so I ended up writing my own Reddit library, but as far as I'm aware the fix in this PR is still valid.

Feel free to re-open this!

kyleratti avatar Apr 26 '22 20:04 kyleratti