Skip to content

Conversation

@sampaiodiego
Copy link
Member

Proposed changes (including videos or screenshots)

This error is happening when visitor is sending the first message:

Exception on find errorClass [Error]: Match error: Failed Match.OneOf, Match.Maybe or Match.Optional validation
    at check (packages/check/match.js:36:17)
    at ns.Collection._getFindOptions (packages/mongo/collection.js:295:7)
    at ns.Collection.find (packages/mongo/collection.js:336:12)
    at BaseDb.find (app/models/server/models/_BaseDb.js:177:21)
    at LivechatDepartment.find (app/models/server/models/_Base.js:106:29)
    at LivechatDepartment.findEnabledWithAgents (app/models/server/models/LivechatDepartment.js:100:15)
    at Object.getRequiredDepartment (app/livechat/server/lib/Livechat.js:125:42)
    at app/livechat/server/lib/Livechat.js:152:29
    at /home/chinello/.meteor/packages/promise/.0.11.2.j40ifr.9pr39++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/meteor-promise/fiber_pool.js:43:40 {
  path: '',
  sanitizedError: errorClass [Error]: Match failed [400]
      at errorClass.<anonymous> (packages/check/match.js:91:27)
      at new errorClass (packages/meteor.js:655:17)
      at check (packages/check/match.js:36:17)
      at ns.Collection._getFindOptions (packages/mongo/collection.js:295:7)
      at ns.Collection.find (packages/mongo/collection.js:336:12)
      at BaseDb.find (app/models/server/models/_BaseDb.js:177:21)
      at LivechatDepartment.find (app/models/server/models/_Base.js:106:29)
      at LivechatDepartment.findEnabledWithAgents (app/models/server/models/LivechatDepartment.js:100:15)
      at Object.getRequiredDepartment (app/livechat/server/lib/Livechat.js:125:42)
      at app/livechat/server/lib/Livechat.js:152:29
      at /home/chinello/.meteor/packages/promise/.0.11.2.j40ifr.9pr39++os+web.browser+web.browser.legacy+web.cordova/npm/node_modules/meteor-promise/fiber_pool.js:43:40 {
    isClientSafe: true,
    error: 400,
    reason: 'Match failed',
    details: undefined,
    errorType: 'Meteor.Error'
  },
  errorType: 'Match.Error'
} { numAgents: { '$gt': 0 }, enabled: true } null

Issue(s)

Steps to test or reproduce

Further comments

@sampaiodiego sampaiodiego merged commit 2078d49 into develop Jun 27, 2021
@sampaiodiego sampaiodiego deleted the fix-livechat-find branch June 27, 2021 18:07
@sampaiodiego sampaiodiego mentioned this pull request Jun 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants