Skip to content

Commit

Permalink
log
Browse files Browse the repository at this point in the history
  • Loading branch information
KevLehman committed Oct 17, 2023
1 parent a1e5c58 commit 97b8979
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions apps/meteor/app/livechat/server/lib/LivechatTyped.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1241,7 +1241,7 @@ class LivechatClass {
}

async returnRoomAsInquiry(room: IOmnichannelRoom, departmentId?: string, overrideTransferData: any = {}) {
Livechat.logger.debug({ msg: `Transfering room to ${departmentId ? 'department' : ''} queue`, room });
this.logger.debug({ msg: `Transfering room to ${departmentId ? 'department' : ''} queue`, room });
if (!room.open) {
throw new Meteor.Error('room-closed');
}
Expand All @@ -1266,7 +1266,7 @@ class LivechatClass {
}

const transferredBy = normalizeTransferredByData(user, room);
Livechat.logger.debug(`Transfering room ${room._id} by user ${transferredBy._id}`);
this.logger.debug(`Transfering room ${room._id} by user ${transferredBy._id}`);
const transferData = { roomId: room._id, scope: 'queue', departmentId, transferredBy, ...overrideTransferData };
try {
await this.saveTransferHistory(room, transferData);
Expand All @@ -1282,7 +1282,6 @@ class LivechatClass {
}

async saveTransferHistory(room: IOmnichannelRoom, transferData: TransferData) {
Livechat.logger.debug(`Saving transfer history for room ${room._id}`);
const { departmentId: previousDepartment } = room;
const { department: nextDepartment, transferredBy, transferredTo, scope, comment } = transferData;

Expand All @@ -1298,7 +1297,7 @@ class LivechatClass {

const { _id, username } = transferredBy;
const scopeData = scope || (nextDepartment ? 'department' : 'agent');
Livechat.logger.debug(`Storing new chat transfer of ${room._id} [Transfered by: ${_id} to ${scopeData}]`);
this.logger.info(`Storing new chat transfer of ${room._id} [Transfered by: ${_id} to ${scopeData}]`);

const transfer = {
transferData: {
Expand Down

0 comments on commit 97b8979

Please sign in to comment.