Skip to content

Commit 2019011

Browse files
jetersenpjdarton
authored andcommitted
fix value accessor in CloudSelectorParameter (#113)
1 parent e53548c commit 2019011

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/main/java/org/jenkinsci/plugins/vsphere/parameters/CloudSelectorParameter.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,10 @@ public StringParameterValue getDefaultParameterValue() {
3535

3636
private StringParameterValue checkValue(StringParameterValue value) {
3737
List<String> cloudNames = vSphereCloud.findAllVsphereCloudNames();
38-
if (!cloudNames.contains(value.value))
39-
throw new IllegalArgumentException("No vsphere cloud with name: " + value.value);
38+
String check = String.valueOf(value.getValue());
39+
if (!cloudNames.contains(check)) {
40+
throw new IllegalArgumentException("No vsphere cloud with name: " + check);
41+
}
4042
return value;
4143
}
4244

0 commit comments

Comments
 (0)