Skip to content

Commit 89a3852

Browse files
committed
use types
1 parent 34e1b61 commit 89a3852

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

v1/providers/shadeform/instancetype.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -233,14 +233,12 @@ func shadeformGPUTypeToBrevGPUName(gpuType string) string {
233233
}
234234

235235
func shadeformCloud(cloud openapi.Cloud) string {
236-
shadeformCloud := string(cloud)
237-
238236
// Shadeform will return the cloud as "excesssupply" if the instance type is retrieved
239237
// from cloud partners and not a direct cloud provider. In this case, we should just return
240238
// the Shadeform Cloud Provider ID.
241-
if strings.EqualFold(shadeformCloud, string(openapi.EXCESSSUPPLY)) {
239+
if cloud == openapi.EXCESSSUPPLY {
242240
return CloudProviderID
243241
}
244242

245-
return shadeformCloud
243+
return string(cloud)
246244
}

0 commit comments

Comments
 (0)