@thzero/library_server 0.15.21 → 0.15.22

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.
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@thzero/library_server",
3
3
  "type": "module",
4
- "version": "0.15.21",
4
+ "version": "0.15.22",
5
5
  "version_major": 0,
6
6
  "version_minor": 15,
7
- "version_patch": 21,
7
+ "version_patch": 22,
8
8
  "version_date": "04/15/2022",
9
9
  "description": "An opinionated library of common functionality to bootstrap a Koa based API application using MongoDb and Firebase.",
10
10
  "author": "thZero",
package/routes/index.js CHANGED
@@ -28,6 +28,8 @@ class BaseRoute {
28
28
 
29
29
  const api = config.get('api', { });
30
30
  let prefix = api.prefix !== null && api.prefix !== undefined ? api.prefix : 'api';
31
+ if (!String.isNullOrEmpty(prefix) && (prefix !== '/'))
32
+ prefix = '/' + prefix;
31
33
 
32
34
  let version = !String.isNullOrEmpty(api.version) ? api.version : null;
33
35
  if (!String.isNullOrEmpty(this._version))
package/routes/utility.js CHANGED
@@ -11,7 +11,7 @@ import authentication from '../middleware/authentication';
11
11
 
12
12
  class UtilityRoute extends BaseRoute {
13
13
  constructor(prefix) {
14
- super(prefix ? prefix : '');
14
+ super(prefix ? prefix : '/utility');
15
15
  }
16
16
 
17
17
  get id() {