properties-file 2.1.30 → 2.1.32

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.
Files changed (2) hide show
  1. package/lib/file/index.js +1 -3
  2. package/package.json +10 -10
package/lib/file/index.js CHANGED
@@ -12,9 +12,7 @@ var content_1 = require("../content/");
12
12
  * @returns A `Properties` object representing the content of a `.properties` file.
13
13
  */
14
14
  var getProperties = function (filePath, encoding) {
15
- if (!(0, node_fs_1.existsSync)(filePath)) {
16
- throw new Error("file not found at ".concat(filePath));
17
- }
15
+ // No need to check if the file exists first since this will already throw an error.
18
16
  return (0, content_1.getProperties)((0, node_fs_1.readFileSync)(filePath, encoding !== null && encoding !== void 0 ? encoding : 'utf8'));
19
17
  };
20
18
  exports.getProperties = getProperties;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "properties-file",
3
- "version": "2.1.30",
3
+ "version": "2.1.32",
4
4
  "description": ".properties file parser, JSON converter and Webpack loader.",
5
5
  "keywords": [
6
6
  ".properties",
@@ -53,12 +53,12 @@
53
53
  },
54
54
  "devDependencies": {
55
55
  "@release-it/conventional-changelog": "^5.1.1",
56
- "@types/jest": "^29.4.0",
57
- "@typescript-eslint/eslint-plugin": "^5.54.0",
58
- "@typescript-eslint/parser": "^5.54.0",
59
- "dotenv-cli": "^7.0.0",
60
- "eslint": "^8.35.0",
61
- "eslint-config-prettier": "^8.6.0",
56
+ "@types/jest": "^29.5.0",
57
+ "@typescript-eslint/eslint-plugin": "^5.55.0",
58
+ "@typescript-eslint/parser": "^5.55.0",
59
+ "dotenv-cli": "^7.1.0",
60
+ "eslint": "^8.36.0",
61
+ "eslint-config-prettier": "^8.7.0",
62
62
  "eslint-import-resolver-node": "^0.3.7",
63
63
  "eslint-import-resolver-typescript": "^3.5.3",
64
64
  "eslint-plugin-import": "^2.27.5",
@@ -68,14 +68,14 @@
68
68
  "eslint-plugin-prettier": "^4.2.1",
69
69
  "eslint-plugin-tsdoc": "^0.2.17",
70
70
  "eslint-plugin-unicorn": "^46.0.0",
71
- "jest": "^29.4.3",
71
+ "jest": "^29.5.0",
72
72
  "prettier": "^2.8.4",
73
73
  "prettier-plugin-organize-imports": "^3.2.2",
74
74
  "prettier-plugin-sh": "^0.12.8",
75
- "release-it": "^15.7.0",
75
+ "release-it": "^15.9.0",
76
76
  "ts-jest": "^29.0.5",
77
77
  "ts-node": "^10.9.1",
78
- "typescript": "^4.9.5"
78
+ "typescript": "^5.0.2"
79
79
  },
80
80
  "engines": {
81
81
  "node": "^14.18.1 || >=16.0.0"