]> git.notmuchmail.org Git - notmuch/blobdiff - bindings/python/notmuch/threads.py
python: fix NULL pointer tests
[notmuch] / bindings / python / notmuch / threads.py
index 690206ef5a9668b6e09ff1b052e7941e373dff75..a6441640605b13bf909d8a7e77c5cc609e98718a 100644 (file)
@@ -14,7 +14,7 @@ for more details.
 You should have received a copy of the GNU General Public License
 along with notmuch.  If not, see <http://www.gnu.org/licenses/>.
 
-Copyright 2010 Sebastian Spaeth <Sebastian@SSpaeth.de>'
+Copyright 2010 Sebastian Spaeth <Sebastian@SSpaeth.de>
 """
 
 from notmuch.globals import (
@@ -172,9 +172,9 @@ class Threads(Python3StringMixIn):
 
     _destroy = nmlib.notmuch_threads_destroy
     _destroy.argtypes = [NotmuchThreadsP]
-    _destroy.argtypes = None
+    _destroy.restype = None
 
     def __del__(self):
         """Close and free the notmuch Threads"""
-        if self._threads is not None:
+        if self._threads:
             self._destroy(self._threads)