Skip to content

Commit

Permalink
Fix issue for PVS-Studio (#14366)
Browse files Browse the repository at this point in the history
  • Loading branch information
Youri970410 authored Mar 2, 2021
1 parent 0b09d42 commit 852b303
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1194,7 +1194,7 @@ private string GetApiTypeForImport(
}
}

return apiType.HasValue ? apiType.Value.ToString("g") : PsApiManagementApiType.Http.ToString("g");
return PsApiManagementApiType.Http.ToString("g");
}

public void ApiAddToProduct(PsApiManagementContext context, string productId, string apiId)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,13 +69,13 @@ public override void ExecuteApiManagementCmdlet()
apiVersionSetId = apiVersionSet.ApiVersionSetId;
}

if (string.IsNullOrEmpty(ApiVersionSetId))
if (string.IsNullOrEmpty(apiVersionSetId))
{
WriteObject(Client.GetApiVersionSets(resourceGroupName, serviceName), true);
}
else
{
WriteObject(Client.GetApiVersionSet(resourceGroupName, serviceName, ApiVersionSetId));
WriteObject(Client.GetApiVersionSet(resourceGroupName, serviceName, apiVersionSetId));
}
}
}
Expand Down

0 comments on commit 852b303

Please sign in to comment.