@simpleplatform/sdk 2.0.0 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +4 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -141,8 +141,10 @@ function readInputFromHost() {
|
|
|
141
141
|
return JSON.stringify(globalThis.__SIMPLE_INITIAL_PAYLOAD__.request);
|
|
142
142
|
}
|
|
143
143
|
// Otherwise, we are in the main WASM module and must read from the host ABI.
|
|
144
|
-
|
|
145
|
-
|
|
144
|
+
// The runtime parses the context on its own side now, so what comes back is a
|
|
145
|
+
// value rather than bytes. Both branches of this function still answer with
|
|
146
|
+
// text because that is what its callers parse.
|
|
147
|
+
return JSON.stringify(host.getContext());
|
|
146
148
|
}
|
|
147
149
|
function returnError(message, context) {
|
|
148
150
|
const response = { data: null, errors: [message], ok: false };
|