From 97484744a7b5022b687d7e34fe63e2a7429652a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=87=E5=A4=A9?= Date: Tue, 12 Mar 2019 14:23:10 +0800 Subject: [PATCH] set dfault charset to utf8mb4 --- index.js | 2 +- package.json | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index a6c1fbb..c89cd86 100644 --- a/index.js +++ b/index.js @@ -40,7 +40,7 @@ class Mysqli { let name = i < 1 ? 'MASTER' : 'SLAVE' + i let collate - charset = charset || 'utf8' + charset = charset || 'utf8mb4' collate = charset + (charset === 'utf8mb4' ? '_unicode_ci' : '_general_ci') diff --git a/package.json b/package.json index 7773b27..e35b6ad 100644 --- a/package.json +++ b/package.json @@ -1,10 +1,10 @@ { "name": "mysqli", - "version": "3.0.5", + "version": "3.0.6", "description": "MySQL tool", "main": "index.js", "dependencies": { - "es.shim": "^1.0.1", + "es.shim": "^1.1.2", "mysql": "^2.13.0" }, "repository": "https://github.com/yutent/mysqli.git",