Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6eab799

Browse files
committed
fix for bug reported by dragoun dash (TypeError: sequence item 0: expected string, NoneType found)
1 parent 468eeb6 commit 6eab799

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

lib/core/common.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,10 @@ def formatDBMSfp(versions=None):
161161
@rtype: C{str}
162162
"""
163163

164-
if ( not versions or versions == [None] ) and kb.dbmsVersion and kb.dbmsVersion[0] != "Unknown":
164+
while None in versions:
165+
versions.remove(None)
166+
167+
if not versions and kb.dbmsVersion and kb.dbmsVersion[0] != "Unknown":
165168
versions = kb.dbmsVersion
166169

167170
if isinstance(versions, basestring):

0 commit comments

Comments
 (0)