From 30a7b044be648ad8e95ed0a124ec4fa2c6c328d2 Mon Sep 17 00:00:00 2001 From: Tom Laird-McConnell Date: Fri, 3 May 2019 14:27:09 -0700 Subject: [PATCH] fix chatdown conversationUpdate to set from and recipient properties --- packages/Chatdown/lib/index.js | 3 +++ packages/Chatdown/package-lock.json | 23 +++++++++++++++-------- packages/Chatdown/package.json | 2 +- 3 files changed, 19 insertions(+), 9 deletions(-) diff --git a/packages/Chatdown/lib/index.js b/packages/Chatdown/lib/index.js index e5c5ccea..1da4b1ae 100644 --- a/packages/Chatdown/lib/index.js +++ b/packages/Chatdown/lib/index.js @@ -159,6 +159,9 @@ function initConversation(args, conversationId, activities) { args.accounts.user = args.accounts[user.toLowerCase()]; } } + conversationUpdate.recipient = args.accounts.bot; + conversationUpdate.from = args.accounts.user; + // define matching statements regex for users args.newMessageRegEx = new RegExp(`^(${args.users.join('|')}|${args.bot}|bot|user)(->(${args.users.join('|')}))??:`, 'i'); activities.push(conversationUpdate); diff --git a/packages/Chatdown/package-lock.json b/packages/Chatdown/package-lock.json index 41b663ad..b148018c 100644 --- a/packages/Chatdown/package-lock.json +++ b/packages/Chatdown/package-lock.json @@ -1,6 +1,6 @@ { "name": "chatdown", - "version": "1.2.0", + "version": "1.2.2", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -643,6 +643,11 @@ "package-json": "^5.0.0" } }, + "lodash": { + "version": "4.17.11", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", + "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + }, "lodash._arraycopy": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/lodash._arraycopy/-/lodash._arraycopy-3.0.0.tgz", @@ -1022,20 +1027,22 @@ } } }, + "request-promise-core": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.2.tgz", + "integrity": "sha512-UHYyq1MO8GsefGEt7EprS8UrXsm1TxEvFUX1IMTuSLU2Rh7fTIdFtl8xD7JiEYiWU2dl+NYAjCTksTehQUxPag==", + "requires": { + "lodash": "^4.17.11" + } + }, "request-promise-native": { "version": "1.0.7", "resolved": "https://registry.npmjs.org/request-promise-native/-/request-promise-native-1.0.7.tgz", "integrity": "sha512-rIMnbBdgNViL37nZ1b3L/VfPOpSi0TqVDQPAvO6U14lMzOLrt5nilxCQqtDKhZeDiW0/hkCXGoQjhgJd/tCh6w==", "requires": { + "request-promise-core": "1.1.2", "stealthy-require": "^1.1.1", "tough-cookie": "^2.3.3" - }, - "dependencies": { - "request-promise-core": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.1.tgz", - "integrity": "sha1-Pu4AssWqgyOc+wTFcA2jb4HNCLY=" - } } }, "responselike": { diff --git a/packages/Chatdown/package.json b/packages/Chatdown/package.json index 8dc69795..69959366 100644 --- a/packages/Chatdown/package.json +++ b/packages/Chatdown/package.json @@ -1,6 +1,6 @@ { "name": "chatdown", - "version": "1.2.1", + "version": "1.2.2", "description": "Tool for parsing chat files and outputting replayable activities", "main": "lib/index.js", "directories": {