1
0
mirror of https://github.com/firstBitMarksistskaya/jenkins-lib.git synced 2024-12-13 11:27:08 +02:00

forEach -> each

This commit is contained in:
Nikita Gryzlov 2020-10-21 11:33:02 +03:00 committed by kuzja086
parent 2f61ef2e36
commit b935f8a7da

View File

@ -32,10 +32,10 @@ class PublishAllure implements Serializable {
List<String> results = new ArrayList<>(); List<String> results = new ArrayList<>();
def allureSubDirs = allurePath.listDirectories() allurePath.listDirectories().each { FilePath filePath ->
if (allureSubDirs.size() > 0) { results.add(filePath.getRemote())
allureSubDirs.forEach({ filePath -> results.add(filePath.getRemote()) }) }
} else { if (results.isEmpty()) {
results.add(allurePath.getRemote()) results.add(allurePath.getRemote())
} }