gojs: refactors out gojs.Config type (#1240)

In order to support more configuration, we should stop using context as
it is getting gnarly.

Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io>
Signed-off-by: Adrian Cole <adrian@tetrate.io>
This commit is contained in:
Takeshi Yoneda
2023-03-14 21:27:47 -07:00
committed by GitHub
parent 00c53d19a2
commit f24a3f49a4
22 changed files with 228 additions and 142 deletions

View File

@@ -539,8 +539,8 @@ type jsfsChown struct{}
func (jsfsChown) invoke(ctx context.Context, mod api.Module, args ...interface{}) (interface{}, error) {
path := resolvePath(ctx, args[0].(string))
uid := goos.ValueToUint32(args[1])
gid := goos.ValueToUint32(args[2])
uid := goos.ValueToInt32(args[1])
gid := goos.ValueToInt32(args[2])
callback := args[3].(funcWrapper)
fsc := mod.(*wasm.CallContext).Sys.FS()