hubot 13.1.1 → 13.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +3 -3
  2. package/src/Robot.mjs +4 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hubot",
3
- "version": "13.1.1",
3
+ "version": "13.1.2",
4
4
  "author": "hubot",
5
5
  "keywords": [
6
6
  "github",
@@ -29,7 +29,7 @@
29
29
  "start": "bin/hubot",
30
30
  "gen": "bin/hubot --create myhubot",
31
31
  "pretest": "standard",
32
- "test": "node --test",
32
+ "test": "node --test --test-timeout=20000",
33
33
  "test:smoke": "node src/**/*.js",
34
34
  "test:e2e": "bin/e2e-test.sh",
35
35
  "build:local": "npx @hubot-friends/sfab --folder ./docs --destination ./_site --verbose --serve /hubot/ --watch-path ./docs --scripts ./sfab-hooks",
@@ -45,6 +45,6 @@
45
45
  "dependencies": {
46
46
  "express": "^5.1.0",
47
47
  "express-basic-auth": "^1.2.1",
48
- "pino": "^9.6.0"
48
+ "pino": "^9.12.0"
49
49
  }
50
50
  }
package/src/Robot.mjs CHANGED
@@ -501,8 +501,9 @@ class Robot {
501
501
  //
502
502
  // Returns nothing.
503
503
  async loadAdapter (adapterPath = null) {
504
- if (this.adapter) {
504
+ if (this.adapter && this.adapter.use) {
505
505
  this.adapter = await this.adapter.use(this)
506
+ this.adapterName = this.adapter.name ?? this.adapter.constructor.name
506
507
  return
507
508
  }
508
509
  this.logger.debug(`Loading adapter ${adapterPath ?? 'from npmjs:'} ${this.adapterName}`)
@@ -521,6 +522,8 @@ class Robot {
521
522
  this.logger.error(`Cannot load adapter ${adapterPath ?? '[no path set]'} ${this.adapterName} - ${error}`)
522
523
  throw error
523
524
  }
525
+
526
+ this.adapterName = this.adapter.name ?? this.adapter.constructor.name
524
527
  }
525
528
 
526
529
  async requireAdapterFrom (adapaterPath) {