Skip to content

Commit

Permalink
fix: sync to es after update ticket
Browse files Browse the repository at this point in the history
  • Loading branch information
uffy committed Aug 5, 2024
1 parent 67a6938 commit 17fc7ba
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions next/api/src/service/ticket.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { createQueue, Job, Queue } from '@/queue';
import { DetectTicketLanguageJobData } from '@/interfaces/ticket';
import { allowedTicketLanguages } from '@/utils/locale';
import { translateService } from './translate';
import { searchTicketService } from '@/service/search-ticket'

interface GetRepliesOptions {
author?: boolean;
Expand Down Expand Up @@ -189,6 +190,7 @@ export class TicketService {
}

await ticket.update({ language }, { useMasterKey: true });
await searchTicketService.addSyncJob([ticket.id])
}

async addDetectTicketLanguageJob(ticketId: string) {
Expand Down

0 comments on commit 17fc7ba

Please sign in to comment.