From cb4ab741f8dbf55dcb6e9086abba5cc293083a4a Mon Sep 17 00:00:00 2001 From: Sergi Almacellas Abellana Date: Thu, 11 Mar 2021 09:15:14 +0100 Subject: [PATCH] Test if integer dict widget value is not None before converting it issue10167 review340211002 --- tryton/gui/window/view_form/view/form_gtk/dictionary.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tryton/gui/window/view_form/view/form_gtk/dictionary.py b/tryton/gui/window/view_form/view/form_gtk/dictionary.py index 414b09b8a8..2f91c22155 100644 --- a/tryton/gui/window/view_form/view/form_gtk/dictionary.py +++ b/tryton/gui/window/view_form/view/form_gtk/dictionary.py @@ -234,7 +234,9 @@ class DictIntegerEntry(DictEntry): return widget def get_value(self): - return int(self.widget.value) + if self.widget.value is not None: + return int(self.widget.value) + return None def set_value(self, value): if value is not None: