@balena/sbvr-types
Advanced tools
Comparing version 4.0.0-build-4-x-088cd25a004362b8ebd6f8a8e502a135d5198f09-1 to 4.0.0-build-4-x-50dfd2d5d5cdbf7a0c2adb132934e4cf7233106e-1
@@ -8,4 +8,5 @@ # Change Log | ||
# v4.0.0 | ||
## (2022-11-25) | ||
## (2022-12-20) | ||
* Set minimum supported nodejs version to 16.13.0 and tsconfig to es2021 [Pagan Gazzard] | ||
* Switch `JSON` to use `JSON` db type instead of `TEXT` [Pagan Gazzard] | ||
@@ -15,2 +16,14 @@ * Switch `Boolean` to use `BOOLEAN` db type instead of `INTEGER` [Pagan Gazzard] | ||
# v3.4.19 | ||
## (2022-12-08) | ||
* Flowzone: Allow external contributions [Josh Bowling] | ||
# v3.4.18 | ||
## (2022-11-25) | ||
* Tests: remove chai-as-promised [Pagan Gazzard] | ||
* Tests: remove bluebird [Pagan Gazzard] | ||
* Tests: remove lodash [Pagan Gazzard] | ||
# v3.4.17 | ||
@@ -17,0 +30,0 @@ ## (2022-11-25) |
@@ -9,3 +9,3 @@ "use strict"; | ||
} | ||
catch (_a) { | ||
catch { | ||
bcrypt = require('bcryptjs'); | ||
@@ -12,0 +12,0 @@ } |
@@ -13,3 +13,8 @@ "use strict"; | ||
}; | ||
const fetchProcessing = (data) => JSON.parse(data); | ||
const fetchProcessing = (data) => { | ||
if (typeof data === 'string') { | ||
return JSON.parse(data); | ||
} | ||
return data; | ||
}; | ||
exports.fetchProcessing = fetchProcessing; | ||
@@ -23,3 +28,3 @@ exports.validate = TypeUtils.validate.checkRequired((value) => { | ||
} | ||
catch (_a) { | ||
catch { | ||
throw new Error('cannot be turned into JSON: ' + value); | ||
@@ -26,0 +31,0 @@ } |
@@ -14,3 +14,3 @@ "use strict"; | ||
} | ||
catch (_a) { | ||
catch { | ||
const shajs = require('sha.js'); | ||
@@ -17,0 +17,0 @@ sha256 = (value) => { |
{ | ||
"name": "@balena/sbvr-types", | ||
"version": "4.0.0-build-4-x-088cd25a004362b8ebd6f8a8e502a135d5198f09-1", | ||
"version": "4.0.0-build-4-x-50dfd2d5d5cdbf7a0c2adb132934e4cf7233106e-1", | ||
"description": "SBVR type definitions.", | ||
@@ -19,3 +19,2 @@ "main": "out", | ||
"license": "BSD", | ||
"dependencies": {}, | ||
"optionalDependencies": { | ||
@@ -30,14 +29,9 @@ "bcrypt": "^5.1.0", | ||
"@types/chai": "^4.3.4", | ||
"@types/chai-as-promised": "^7.1.5", | ||
"@types/chai-datetime": "^0.0.37", | ||
"@types/lodash": "^4.14.190", | ||
"@types/mocha": "^10.0.0", | ||
"@types/sha.js": "^2.4.0", | ||
"bluebird": "^3.7.2", | ||
"chai": "^4.3.7", | ||
"chai-as-promised": "^7.1.1", | ||
"chai-datetime": "^1.8.0", | ||
"husky": "^8.0.2", | ||
"lint-staged": "^13.0.4", | ||
"lodash": "^4.17.21", | ||
"mocha": "^10.1.0", | ||
@@ -62,5 +56,8 @@ "require-npm4-to-publish": "^1.0.0", | ||
}, | ||
"engines": { | ||
"node": ">=16.13.0" | ||
}, | ||
"versionist": { | ||
"publishedAt": "2022-11-25T16:31:51.679Z" | ||
"publishedAt": "2022-12-20T16:00:02.567Z" | ||
} | ||
} |
@@ -12,3 +12,8 @@ import * as TypeUtils from '../type-utils'; | ||
export const fetchProcessing = (data: any) => JSON.parse(data); | ||
export const fetchProcessing = (data: any) => { | ||
if (typeof data === 'string') { | ||
return JSON.parse(data); | ||
} | ||
return data; | ||
}; | ||
@@ -15,0 +20,0 @@ export const validate = TypeUtils.validate.checkRequired((value) => { |
{ | ||
"compilerOptions": { | ||
"module": "commonjs", | ||
"target": "es2018", | ||
"target": "es2021", | ||
"strict": true, | ||
@@ -6,0 +6,0 @@ "noImplicitAny": true, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
111419
14
1654