mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-26 11:34:58 +02:00
UBERF-6161: Storage configuration (#5109)
Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
@@ -39,7 +39,7 @@ export async function removeDocument (
|
||||
const historyDocumentId = collaborativeHistoryDocId(minioDocumentId)
|
||||
|
||||
try {
|
||||
await minio.remove(workspaceId, [minioDocumentId, historyDocumentId])
|
||||
await minio.remove(ctx, workspaceId, [minioDocumentId, historyDocumentId])
|
||||
} catch (err) {
|
||||
await ctx.error('failed to remove document', { documentId, error: err })
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ export async function takeSnapshot (
|
||||
const historyDocumentId = collaborativeHistoryDocId(minioDocumentId)
|
||||
const yHistory =
|
||||
(await ctx.with('yDocFromMinio', {}, async () => {
|
||||
return await yDocFromStorage(minio, workspaceId, historyDocumentId)
|
||||
return await yDocFromStorage(ctx, minio, workspaceId, historyDocumentId)
|
||||
})) ?? new YDoc()
|
||||
|
||||
await ctx.with('createYdocSnapshot', {}, async () => {
|
||||
@@ -67,7 +67,7 @@ export async function takeSnapshot (
|
||||
})
|
||||
|
||||
await ctx.with('yDocToMinio', {}, async () => {
|
||||
await yDocToStorage(minio, workspaceId, historyDocumentId, yHistory)
|
||||
await yDocToStorage(ctx, minio, workspaceId, historyDocumentId, yHistory)
|
||||
})
|
||||
|
||||
return { ...version }
|
||||
|
||||
Reference in New Issue
Block a user