]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/Workspace/WorkspaceDatabase.py
BaseTools: Remove equality operator with None
[mirror_edk2.git] / BaseTools / Source / Python / Workspace / WorkspaceDatabase.py
index a3407d113e0f437dbb2b6a5af65cd65d1a3969d8..2b888c0610c32576fd7168093183b76021723498 100644 (file)
@@ -214,7 +214,7 @@ class WorkspaceDatabase(object):
         else:\r
             curPath  = os.path.dirname(__file__) # curPath is the path of WorkspaceDatabase.py\r
             rootPath = os.path.split(curPath)[0] # rootPath is root path of python source, such as /BaseTools/Source/Python\r
-            if rootPath == "" or rootPath == None:\r
+            if rootPath == "" or rootPath is None:\r
                 EdkLogger.verbose("\nFail to find the root path of build.exe or python sources, so can not \\r
 determine whether database file is out of date!\n")\r
         \r
@@ -308,13 +308,13 @@ determine whether database file is out of date!\n")
                 Platform = self.BuildObject[PathClass(PlatformFile), 'COMMON']\r
             except:\r
                 Platform = None\r
-            if Platform != None:\r
+            if Platform is not None:\r
                 PlatformList.append(Platform)\r
         return PlatformList\r
 \r
     def _MapPlatform(self, Dscfile):\r
         Platform = self.BuildObject[PathClass(Dscfile), 'COMMON']\r
-        if Platform == None:\r
+        if Platform is None:\r
             EdkLogger.error('build', PARSER_ERROR, "Failed to parser DSC file: %s" % Dscfile)\r
         return Platform\r
 \r