diff --git a/gramps/cli/plug/__init__.py b/gramps/cli/plug/__init__.py index 299bf0add..b1c1d37b1 100644 --- a/gramps/cli/plug/__init__.py +++ b/gramps/cli/plug/__init__.py @@ -88,9 +88,9 @@ def _convert_str_to_match_type(str_val, type_val): return str(str_val) elif ret_type == int: - if str_val.isdigit(): + try: return int(str_val) - else: + except ValueError: print("'%s' is not an integer number" % str_val) return 0