Closed emaayan closed 1 month ago
In case it's still relevant: you can access extra arguments by calling Js.arguments()
. Alternatively you can define your own class for the promise, similar to elemental2.promise.Promise
, but change CatchOnRejectedCallbackFn
to accept multiple arguments (since this is a difference between standard Promise and Cockpit API, it should not be part of Elemental).
@jDramaix can this be closed as non-issue?
Done. Thanks for the follow-up.
hi.. according to cockpit promises, the catch portion may return an additional parameter https://cockpit-project.org/guide/latest/cockpit-spawn.html from what i understand you can't have more then one value on a callback in promise