mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
send direct message
This commit is contained in:
+5
-3
@@ -15,7 +15,7 @@ export class SocketMessageUpdateUseCaseService {
|
||||
) { }
|
||||
|
||||
|
||||
@XTracerAsync({name:'Socket-Message-Update-UseCase', bugPrint: true})
|
||||
@XTracerAsync({name:'Socket-Message-Update-UseCase', bugPrint: true, module:'chat',})
|
||||
async execute(data: MessageOutPutDataDTO, tracing?: TracingType) {
|
||||
|
||||
ParamsValidation(MessageOutPutDataDTOSchema, data, tracing)
|
||||
@@ -30,11 +30,13 @@ export class SocketMessageUpdateUseCaseService {
|
||||
|
||||
if(result.isOk()) {
|
||||
tracing?.addEvent("Message found")
|
||||
return await this.messageLocalDataSourceService.update(result.value.$id, incomingMessage)
|
||||
const updateResult = await this.messageLocalDataSourceService.update(result.value.$id, incomingMessage)
|
||||
tracing.setAttribute('outcome', 'success')
|
||||
return updateResult
|
||||
} else {
|
||||
tracing?.addEvent("Message not found")
|
||||
}
|
||||
|
||||
tracing.setAttribute('outcome', 'success')
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user