chore: add return type to IOLib.addTo
ci/woodpecker/push/woodpecker Pipeline was successful
Details
ci/woodpecker/push/woodpecker Pipeline was successful
Details
This commit is contained in:
parent
8c37393edf
commit
86e34a1f16
|
@ -23,7 +23,7 @@ publishing {
|
|||
}
|
||||
|
||||
tasks.compileKotlin {
|
||||
destinationDirectory = tasks.compileJava.get().destinationDir
|
||||
destinationDirectory = tasks.compileJava.get().destinationDirectory.asFile.orNull
|
||||
}
|
||||
|
||||
tasks.javadoc {
|
||||
|
|
|
@ -10,7 +10,7 @@ import io.gitlab.jfronny.muscript.data.dynamic.additional.DFinal;
|
|||
import java.util.List;
|
||||
|
||||
public class IOLib {
|
||||
public static void addTo(MuScriptVersion version, Scope scope, IOWrapper io) {
|
||||
public static Scope addTo(MuScriptVersion version, Scope scope, IOWrapper io) {
|
||||
if (version.contains(MuScriptVersion.V3)) {
|
||||
scope.set("readString", args -> {
|
||||
if (args.size() != 1) throw new IllegalArgumentException("Invalid number of arguments for readString: expected 1 but got " + args.size());
|
||||
|
@ -23,5 +23,6 @@ public class IOLib {
|
|||
return script.bindTo(scope.fork()).call(innerArgs);
|
||||
});
|
||||
}
|
||||
return scope;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue