Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@cs-chatbots/router-masterbot-tools

Package Overview
Dependencies
Maintainers
4
Versions
434
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cs-chatbots/router-masterbot-tools - npm Package Compare versions

Comparing version 0.1.3 to 0.1.4

.npmignore

2

package.json
{
"name": "@cs-chatbots/router-masterbot-tools",
"version": "0.1.3",
"version": "0.1.4",
"description": "",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -28,2 +28,3 @@ # Router Masterbot Tools

3. Overrides `Responder.trackAsSkill()` to store the skill not only in the
conversation state but also in the shared context.
conversation state but also in the shared context. Additionally, it saves appId
in shared context every time a skill is stored.

@@ -57,5 +57,9 @@ 'use strict';

_overrideTrackAsSkill (req, res) {
const { appId } = res.data;
res._trackAsSkillOrig = res._trackAsSkillOrig || res.trackAsSkill;
res.trackAsSkill = (skill) => {
res.setSharedContext({ trackAsSkill: skill });
res.setSharedContext({
trackAsSkill: skill,
appId
});
return res._trackAsSkillOrig(req, req);

@@ -62,0 +66,0 @@ };

@@ -82,3 +82,3 @@ 'use strict';

expect(data.setSharedContext).toStrictEqual(
{ trackAsSkill: 's' }
{ trackAsSkill: 's', appId: 'bot' }
);

@@ -89,3 +89,5 @@ _send.call(res, data);

});
await this._getTester(bot).postBack('/track');
const t = this._getTester(bot);
t.testData = { appId: 'bot' };
await t.postBack('/track');
});

@@ -92,0 +94,0 @@ }

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc