Added Null check around SetupMetaData