I think this check should actually be `if user is None`. Currently, `if not user` will evaluate to `true` for `user` values of empty string, integer zero, boolean false, etc. It's highly unlikely this case would ever happen without severe errors in  the DB model, but from a Python standpoint we want to compare to `None`, and nothing else (since that's the sentinel value used by `fetch_user()` to indicate `"no records found"`.