From 58ff337acf899a72b867be2f8acc203b340f0e15 Mon Sep 17 00:00:00 2001 From: alancucki Date: Mon, 13 Nov 2017 14:36:56 -0500 Subject: [PATCH] Fix extra_data can be 0 --- lshash/lshash.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lshash/lshash.py b/lshash/lshash.py index 5c895a6..750b731 100644 --- a/lshash/lshash.py +++ b/lshash/lshash.py @@ -195,7 +195,7 @@ def index(self, input_point, extra_data=None): if isinstance(input_point, np.ndarray): input_point = input_point.tolist() - if extra_data: + if extra_data is not None: value = (tuple(input_point), extra_data) else: value = tuple(input_point)