@axiom-lattice/gateway 2.1.113 → 2.1.114
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/.turbo/turbo-build.log +8 -8
- package/CHANGELOG.md +6 -0
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/controllers/workspace.ts +3 -3
package/dist/index.mjs
CHANGED
|
@@ -4428,7 +4428,7 @@ var WorkspaceController = class {
|
|
|
4428
4428
|
async uploadFile(request, reply) {
|
|
4429
4429
|
const tenantId = this.getTenantId(request);
|
|
4430
4430
|
const { workspaceId, projectId } = request.params;
|
|
4431
|
-
const assistantId = request.query.assistantId;
|
|
4431
|
+
const assistantId = request.query.assistantId || request.headers["x-assistant-id"];
|
|
4432
4432
|
const workspace = await this.workspaceStore.getWorkspaceById(
|
|
4433
4433
|
tenantId,
|
|
4434
4434
|
workspaceId
|
|
@@ -4462,6 +4462,8 @@ var WorkspaceController = class {
|
|
|
4462
4462
|
const volumeBackend = await sandboxManager.getVolumeBackendForPath(volumeConfig, realPath);
|
|
4463
4463
|
if (volumeBackend && !isBinary) {
|
|
4464
4464
|
await volumeBackend.write(realPath, buffer.toString("utf-8"));
|
|
4465
|
+
} else if (volumeBackend && volumeBackend.writeBinary) {
|
|
4466
|
+
await volumeBackend.writeBinary(realPath, buffer);
|
|
4465
4467
|
} else {
|
|
4466
4468
|
const sandbox = await sandboxManager.getSandboxFromConfig(volumeConfig);
|
|
4467
4469
|
await sandbox.file.uploadFile({ file: realPath, data: buffer });
|