Browse Source

Add pickle support to TVInfoShow so diskcache can be used.

tags/release_0.25.1
Prinz23 4 years ago
committed by JackDandy
parent
commit
b8a1919d81
  1. 12
      lib/tvinfo_base/base.py

12
lib/tvinfo_base/base.py

@ -384,6 +384,18 @@ class TVInfoShow(dict):
return results
def __getstate__(self):
d = dict(self.__dict__)
try:
del d['lock']
except (BaseException, Exception):
pass
return d
def __setstate__(self, d):
self.__dict__ = d
self.lock = threading.RLock()
__repr__ = __str__
__nonzero__ = __bool__

Loading…
Cancel
Save