@athenna/http 1.5.8 → 1.5.9

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,6 +1,6 @@
1
1
  {
2
2
  "name": "@athenna/http",
3
- "version": "1.5.8",
3
+ "version": "1.5.9",
4
4
  "description": "The Athenna Http server. Built on top of fastify.",
5
5
  "license": "MIT",
6
6
  "author": "João Lenon <lenon@athenna.io>",
@@ -7,7 +7,7 @@
7
7
  * file that was distributed with this source code.
8
8
  */
9
9
 
10
- import { Path } from '@secjs/utils'
10
+ import { Path, String } from '@secjs/utils'
11
11
  import { Command, FilePropertiesHelper } from '@athenna/artisan'
12
12
 
13
13
  export class MakeMiddleware extends Command {
@@ -67,7 +67,9 @@ export class MakeMiddleware extends Command {
67
67
  await FilePropertiesHelper.addContentToObjectGetter(
68
68
  Path.http('Kernel.js'),
69
69
  'namedMiddlewares',
70
- `import('#app/Http/Middlewares/${name}')`,
70
+ `${String.toCamelCase(
71
+ file.name,
72
+ )}: import('#app/Http/Middlewares/${name}')`,
71
73
  )
72
74
  }
73
75
  }