diff options
Diffstat (limited to 'app/utils.py')
-rw-r--r-- | app/utils.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/utils.py b/app/utils.py index 07337b6..618a4aa 100644 --- a/app/utils.py +++ b/app/utils.py @@ -218,3 +218,9 @@ def isYes(val): def isNo(val): return val and not isYes(val) + +def nonEmptyOrNone(str): + if str is None or str == "": + return None + + return str |