File tree 2 files changed +5
-3
lines changed
src/main/java/se/bjurr/gitchangelog/api/helpers
2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ dependencies {
18
18
19
19
testImplementation ' org.slf4j:slf4j-simple:2.0.16'
20
20
testImplementation ' junit:junit:4.13.2'
21
- testImplementation ' org.assertj:assertj-core:3.27.2 '
21
+ testImplementation ' org.assertj:assertj-core:3.27.3 '
22
22
testImplementation ' com.approvaltests:approvaltests:24.14.2'
23
23
testImplementation ' org.mockito:mockito-core:5.15.2'
24
24
}
Original file line number Diff line number Diff line change 28
28
import com .github .jknack .handlebars .Options .Buffer ;
29
29
import com .github .jknack .handlebars .helper .EachHelper ;
30
30
import java .io .IOException ;
31
+ import java .util .ArrayList ;
31
32
import java .util .Collections ;
32
33
import java .util .List ;
33
34
import java .util .Map ;
@@ -243,8 +244,9 @@ public static Map<String, Helper<?>> getAll() {
243
244
helpers .put (
244
245
"eachUrlPart" ,
245
246
(final Changelog changelog , final Options options ) -> {
246
- Collections .reverse (changelog .getUrlParts ());
247
- return each (options , changelog .getUrlParts ());
247
+ List <String > reversedList = new ArrayList <>(changelog .getUrlParts ());
248
+ Collections .reverse (reversedList );
249
+ return each (options , reversedList );
248
250
});
249
251
return helpers ;
250
252
}
You can’t perform that action at this time.
0 commit comments