From e25b523fc5c119ed3349d0d41f1d36e927eec6bd Mon Sep 17 00:00:00 2001 From: Gerald Britton Date: Thu, 17 Feb 2011 17:03:09 +0000 Subject: [PATCH] Fix bug in version_str_to_tup svn: r16651 --- src/gen/plug/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gen/plug/utils.py b/src/gen/plug/utils.py index 81e84d49c..0510974d0 100644 --- a/src/gen/plug/utils.py +++ b/src/gen/plug/utils.py @@ -88,7 +88,7 @@ def version_str_to_tup(sversion, positions): tup += (0,) * (positions - len(tup)) except: tup = (0,) * positions - return tup + return tup[:positions] class newplugin(object): """ @@ -257,7 +257,7 @@ def load_addon_file(path, callback=None): gramps_target_version = results.get("gramps_target_version", None) id = results.get("id", None) if gramps_target_version: - vtup = version_str_to_tup(gramps_target_version, 2) + # Is it for the right version of gramps? if vtup == const.VERSION_TUPLE[0:2]: # If this version is not installed, or > installed, install it