ff689c8
@@ -133,7 +133,7 @@
raise NotImplementedError
def _str_export_value(self):
- if self._assigned_value:
+ if self._assigned_value is not None:
return str(self._assigned_value)
return None
Without this, if we try to set a string-type config option to '' it becomes None. When code expecting a string uses this value, it ends up expanding out to 'None' in various places, including the plugin configuration pages.
Signed-off-by: Howard Johnson merlin@merlinthp.org
Simple reproducer for the issue:
The empty field turns into 'None' on page reload. If you log out, then navigate back to the login page, you'll see the help text is now 'None'.
This patch looks good to me.
Commit c873faa fixes this pull-request
Pull-Request has been merged by merlin@merlinthp.org
Without this, if we try to set a string-type config option to '' it becomes
None. When code expecting a string uses this value, it ends up expanding
out to 'None' in various places, including the plugin configuration pages.
Signed-off-by: Howard Johnson merlin@merlinthp.org