Skip to content

Commit ae3bed9

Browse files
committed
fix: event typo
1 parent 4c529e8 commit ae3bed9

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

packages/backend/server/src/__tests__/copilot.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1353,7 +1353,7 @@ test('should be able to manage context', async t => {
13531353
});
13541354

13551355
t.assert(
1356-
handler.lastCall.calledWith('workspace.file.embed.finish', {
1356+
handler.lastCall.calledWith('workspace.file.embed.finished', {
13571357
contextId: session.id,
13581358
fileId: file.id,
13591359
chunkSize: 3,

packages/backend/server/src/plugins/copilot/context/job.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ export class CopilotContextDocJob implements OnModuleInit {
154154
`;
155155
}
156156

157-
this.event.emit('workspace.file.embed.finish', {
157+
this.event.emit('workspace.file.embed.finished', {
158158
contextId,
159159
fileId,
160160
chunkSize: total,

packages/backend/server/src/plugins/copilot/context/service.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,12 +163,12 @@ export class CopilotContextService implements OnModuleInit {
163163
return null;
164164
}
165165

166-
@OnEvent('workspace.file.embed.finish')
166+
@OnEvent('workspace.file.embed.finished')
167167
async onFileEmbedFinish({
168168
contextId,
169169
fileId,
170170
chunkSize,
171-
}: Events['workspace.file.embed.finish']) {
171+
}: Events['workspace.file.embed.finished']) {
172172
const context = await this.get(contextId);
173173
await context.saveFileRecord(fileId, file => ({
174174
...(file as ContextFile),

packages/backend/server/src/plugins/copilot/context/types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ declare global {
1111
workspaceId: string;
1212
docId: string;
1313
}>;
14-
'workspace.file.embed.finish': {
14+
'workspace.file.embed.finished': {
1515
contextId: string;
1616
fileId: string;
1717
chunkSize: number;

0 commit comments

Comments
 (0)