diff --git a/server/api/controllers/deposit.js b/server/api/controllers/deposit.js index 3cd2a7ae4b..bfcc1b192c 100644 --- a/server/api/controllers/deposit.js +++ b/server/api/controllers/deposit.js @@ -30,6 +30,10 @@ const getAdminDeposits = (req, res) => { format } = req.swagger.params; + if (format.value && req.auth.scopes.indexOf(ROLES.ADMIN) === -1 && !user_id.value) { + return res.status(403).json({ message: API_KEY_NOT_PERMITTED }); + } + toolsLib.wallet.getUserDepositsByKitId( user_id.value, currency.value, diff --git a/server/api/controllers/withdrawal.js b/server/api/controllers/withdrawal.js index 9b7b6ca55b..d79c4a98d2 100644 --- a/server/api/controllers/withdrawal.js +++ b/server/api/controllers/withdrawal.js @@ -267,7 +267,7 @@ const getAdminWithdrawals = (req, res) => { address } = req.swagger.params; - if (format.value && req.auth.scopes.indexOf(ROLES.ADMIN) === -1) { + if (format.value && req.auth.scopes.indexOf(ROLES.ADMIN) === -1 && !user_id.value) { return res.status(403).json({ message: API_KEY_NOT_PERMITTED }); } diff --git a/server/api/swagger/admin.yaml b/server/api/swagger/admin.yaml index 26b48f582a..ae4e263209 100644 --- a/server/api/swagger/admin.yaml +++ b/server/api/swagger/admin.yaml @@ -2669,6 +2669,8 @@ paths: x-security-scopes: - admin - supervisor + - kyc + - support x-token-permissions: - can_read /admin/user/referer: @@ -2699,6 +2701,9 @@ paths: - hmac x-security-scopes: - admin + - supervisor + - kyc + - support x-token-permissions: - can_read /admin/user/wallet: diff --git a/server/api/swagger/common.yaml b/server/api/swagger/common.yaml index 4d475016ab..0434fbddac 100644 --- a/server/api/swagger/common.yaml +++ b/server/api/swagger/common.yaml @@ -264,7 +264,7 @@ paths: in: query required: false type: string - maxLength: 1024 + maxLength: 5000 responses: 200: description: Success diff --git a/server/api/swagger/definitions.yaml b/server/api/swagger/definitions.yaml index 6c8edd2d74..8ba3981b27 100644 --- a/server/api/swagger/definitions.yaml +++ b/server/api/swagger/definitions.yaml @@ -25,7 +25,7 @@ definitions: maxLength: 256 captcha: type: string - maxLength: 1024 + maxLength: 5000 referral: type: string maxLength: 256 diff --git a/server/api/swagger/swagger.js b/server/api/swagger/swagger.js index 0811ec54af..f8496ed2da 100644 --- a/server/api/swagger/swagger.js +++ b/server/api/swagger/swagger.js @@ -4,7 +4,7 @@ const definition = { swagger: '2.0', info: { title: 'HollaEx Kit', - version: '2.6.4' + version: '2.6.5' }, host: 'api.hollaex.com', basePath: '/v2', diff --git a/server/package.json b/server/package.json index 6499feae3e..51e5e03167 100644 --- a/server/package.json +++ b/server/package.json @@ -1,5 +1,5 @@ { - "version": "2.6.4", + "version": "2.6.5", "private": false, "description": "HollaEx Kit", "keywords": [ diff --git a/templates/local/nginx/nginx.conf b/templates/local/nginx/nginx.conf index 0345f411da..d11e876781 100644 --- a/templates/local/nginx/nginx.conf +++ b/templates/local/nginx/nginx.conf @@ -10,6 +10,14 @@ events { } http { + gzip on; + gzip_comp_level 6; + gzip_min_length 500; + gzip_buffers 16 8k; + gzip_proxied any; + gzip_vary on; + gzip_types text/plain text/css application/json application/x-javascript application/javascript text/xml application/xml application/rss+xml text/javascript image/svg+xml application/vnd.ms-fo + include /etc/nginx/mime.types; include /etc/nginx/proxy.conf; include /etc/nginx/conf.d/upstream*.conf; diff --git a/version b/version index e46a05b196..68167133b9 100644 --- a/version +++ b/version @@ -1 +1 @@ -2.6.4 \ No newline at end of file +2.6.5 \ No newline at end of file diff --git a/web/package-lock.json b/web/package-lock.json index 7e5d7f3080..00d18238f1 100644 --- a/web/package-lock.json +++ b/web/package-lock.json @@ -1,6 +1,6 @@ { "name": "hollaex-kit", - "version": "2.6.4", + "version": "2.6.5", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/web/package.json b/web/package.json index 1687c058f0..6ae9da121f 100644 --- a/web/package.json +++ b/web/package.json @@ -1,6 +1,6 @@ { "name": "hollaex-kit", - "version": "2.6.4", + "version": "2.6.5", "private": true, "dependencies": { "@ant-design/compatible": "1.0.5", diff --git a/web/src/components/Form/FormFields/FieldWrapper.js b/web/src/components/Form/FormFields/FieldWrapper.js index e568af59b6..21c97ae5eb 100644 --- a/web/src/components/Form/FormFields/FieldWrapper.js +++ b/web/src/components/Form/FormFields/FieldWrapper.js @@ -14,22 +14,21 @@ const Warning = ({ text, className = '' }) => ( ); -const renderWarning = (warning) => { - if (warning) { - if (Array.isArray(warning)) { - return ( -