diff --git a/roundup/cgi/templating.py b/roundup/cgi/templating.py index 454b312..ed5f9cd 100644 --- a/roundup/cgi/templating.py +++ b/roundup/cgi/templating.py @@ -821,10 +821,14 @@ class _HTMLItem(HTMLInputMixin, HTMLPermissions): # pre-load the history with the current state current = {} for prop_n in self._props.keys(): - prop = self[prop_n] - if not isinstance(prop, HTMLProperty): - continue - current[prop_n] = prop.plain(escape=1) + # get the current prop value if one exists in the DB + if self._klass.get(self._nodeid, prop_n): + prop = self[prop_n] + if not isinstance(prop, HTMLProperty): + continue + current[prop_n] = prop.plain(escape=1) + else: + current[prop_n] = '' # make link if hrefable if (self._props.has_key(prop_n) and isinstance(self._props[prop_n], hyperdb.Link)):