From c93356ada99e6f8083a64f99d162b44a2765ce63 Mon Sep 17 00:00:00 2001 From: "Carsey, Jaben" Date: Fri, 20 Apr 2018 23:51:42 +0800 Subject: BaseTools: remove redundant if comparison inherently python will check string and list for None and having data if in [None, ''] and similar are superflous. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Jaben Carsey Reviewed-by: Yonghong Zhu --- BaseTools/Source/Python/Workspace/InfBuildData.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'BaseTools/Source/Python/Workspace/InfBuildData.py') diff --git a/BaseTools/Source/Python/Workspace/InfBuildData.py b/BaseTools/Source/Python/Workspace/InfBuildData.py index cf5e1df3a5..602746de32 100644 --- a/BaseTools/Source/Python/Workspace/InfBuildData.py +++ b/BaseTools/Source/Python/Workspace/InfBuildData.py @@ -1116,7 +1116,7 @@ class InfBuildData(ModuleBuildClassObject): Pcd.DatumType = PcdInPackage.DatumType Pcd.MaxDatumSize = PcdInPackage.MaxDatumSize Pcd.InfDefaultValue = Pcd.DefaultValue - if Pcd.DefaultValue in [None, '']: + if not Pcd.DefaultValue: Pcd.DefaultValue = PcdInPackage.DefaultValue else: try: -- cgit v1.2.3