Skip to content

Commit e76dadf

Browse files
committed
cleanup: use lambda
1 parent b49311a commit e76dadf

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/main/java/com/dtolabs/rundeck/plugin/resources/ec2/EC2ResourceModelSourceFactory.java

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -203,13 +203,11 @@ public ResourceModelSource createResourceModelSource(Properties configuration) t
203203
"separated by \";\"",
204204
false, null))
205205
.property(PropertyUtil.string(MAPPING_FILE, "Mapping File", "Property mapping File", false, null,
206-
new PropertyValidator() {
207-
public boolean isValid(final String s) throws ValidationException {
208-
if (!new File(s).isFile()) {
209-
throw new ValidationException("File does not exist: " + s);
210-
}
211-
return true;
206+
s -> {
207+
if (!new File(s).isFile()) {
208+
throw new ValidationException("File does not exist: " + s);
212209
}
210+
return true;
213211
}))
214212
.property(PropertyUtil.bool(USE_DEFAULT_MAPPING, "Use Default Mapping",
215213
"Start with default mapping definition. (Defaults will automatically be used if no others are " +

0 commit comments

Comments
 (0)