diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b8f3356..8fc3d56 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,10 +14,9 @@ jobs: strategy: matrix: node-version: - - 10 - - 12 - 14 - 16 + - 18 db: - mysql:8.0 name: Node.js ${{ matrix.node }} - ${{ matrix.db }} diff --git a/index.js b/index.js index 39794e3..b741275 100644 --- a/index.js +++ b/index.js @@ -46,8 +46,8 @@ function fastifyMysql (fastify, options, next) { } module.exports = fp(fastifyMysql, { - fastify: '>=1.0.0', - name: 'fastify-mysql' + fastify: '4.x', + name: '@fastify/mysql' }) function _createConnection ({ connectionType, options, usePromise }, cb) { @@ -55,9 +55,9 @@ function _createConnection ({ connectionType, options, usePromise }, cb) { const mysql = usePromise ? require('mysql2/promise') : require('mysql2') const db = { - format: format, - escape: escape, - escapeId: escapeId + format, + escape, + escapeId } let client = {} diff --git a/package.json b/package.json index cc88fd3..defa02f 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ }, "devDependencies": { "@types/node": "^17.0.0", - "fastify": "^3.0.0", + "fastify": "^4.0.0-rc.2", "standard": "^17.0.0", "tap": "^16.0.0", "tsd": "^0.20.0"