@darksheep/logger 1.0.10 โ†’ 1.1.0

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.1.0](https://github.com/DarkSheepSoftware/node-packages/compare/logger-v1.0.10...logger-v1.1.0) (2025-03-25)
4
+
5
+
6
+ ### ๐ŸŒŸ Features
7
+
8
+ * Allow new lines in filters ([0aeb3d2](https://github.com/DarkSheepSoftware/node-packages/commit/0aeb3d20f699d883d55948fdec933683274e3122))
9
+
10
+
11
+ ### ๐Ÿฉน Fixes
12
+
13
+ * Prevent null killing the replacer ([4f51ee7](https://github.com/DarkSheepSoftware/node-packages/commit/4f51ee77f90adfc145ebf4479a52450eea149d55))
14
+
15
+
16
+ ### ๐Ÿ“š Documentation
17
+
18
+ * fix up example ([bbf8e18](https://github.com/DarkSheepSoftware/node-packages/commit/bbf8e187c4a19fa046f4d3beb5c41224ed9b2c8b))
19
+
20
+
21
+ ### ๐Ÿ“ฆ Dependencies
22
+
23
+ * **pkg:** update dependency deepmerge-ts to v7.1.5 ([#575](https://github.com/DarkSheepSoftware/node-packages/issues/575)) ([88903f3](https://github.com/DarkSheepSoftware/node-packages/commit/88903f3d27484bfbe4ac0834ec8edb77b09efd4c))
24
+ * **pkg:** update dependency stacktrace-parser to v0.1.11 ([#570](https://github.com/DarkSheepSoftware/node-packages/issues/570)) ([ebd3ac9](https://github.com/DarkSheepSoftware/node-packages/commit/ebd3ac9ce34133a979f9b6d08f534f4fbee74878))
25
+
26
+
27
+ ### ๐Ÿงน Chores
28
+
29
+ * Remove zod from tests ([#564](https://github.com/DarkSheepSoftware/node-packages/issues/564)) ([22259db](https://github.com/DarkSheepSoftware/node-packages/commit/22259dbf3202f03771c609b66170c788c68c7366))
30
+
3
31
  ## [1.0.10](https://github.com/DarkSheepSoftware/node-packages/compare/logger-v1.0.9...logger-v1.0.10) (2025-01-28)
4
32
 
5
33
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@darksheep/logger",
3
- "version": "1.0.10",
3
+ "version": "1.1.0",
4
4
  "description": "Logging your stuff to where ever you want it",
5
5
  "license": "UNLICENCED",
6
6
  "type": "module",
@@ -13,8 +13,7 @@
13
13
  "files": [
14
14
  "src",
15
15
  "types",
16
- "!*.test.*",
17
- "!assert.zod.js"
16
+ "!*.test.*"
18
17
  ],
19
18
  "scripts": {
20
19
  "prepack": "yarn dlx -q -p typescript tsc",
@@ -23,14 +22,13 @@
23
22
  },
24
23
  "dependencies": {
25
24
  "@darksheep/environment": "3.1.0",
26
- "deepmerge-ts": "7.1.4",
27
- "stacktrace-parser": "0.1.10",
25
+ "deepmerge-ts": "7.1.5",
26
+ "stacktrace-parser": "0.1.11",
28
27
  "traverse": "0.6.11"
29
28
  },
30
29
  "devDependencies": {
31
30
  "@types/traverse": "~0.6.33",
32
- "nock": "~14.0.0",
33
- "zod": "~3.24.0"
31
+ "nock": "~14.0.0"
34
32
  },
35
33
  "engines": {
36
34
  "node": "^20.13.1 || ^22.2.0"
package/src/replacer.js CHANGED
@@ -64,7 +64,7 @@ export function replace(object, replacers = []) {
64
64
  return this.update({ $class: value.constructor.name });
65
65
  }
66
66
 
67
- if (Object.getPrototypeOf(value).constructor === Object) {
67
+ if (Object.getPrototypeOf(value)?.constructor === Object) {
68
68
  this.update({ ...value });
69
69
  }
70
70
 
@@ -8,7 +8,9 @@ const multiLevelWildcard = /.*/u;
8
8
  * @returns {{ allowed: RegExp[], blocked: RegExp[] }}
9
9
  */
10
10
  export function parseFilters(filter = '', fallback = []) {
11
- const filters = filter.split(',');
11
+ const filters = filter
12
+ .split(',')
13
+ .map((str) => str.trim());
12
14
 
13
15
  const allowed = [];
14
16
  const blocked = [];
@@ -1,18 +0,0 @@
1
- /**
2
- * @param {unknown} input - The input to convert to a zod schema.
3
- * @returns {ZodType}
4
- */
5
- export function convertToZod(input: unknown): ZodType;
6
- /**
7
- * @param {unknown} input - The input object test with.
8
- * @returns {ZodType}
9
- */
10
- export function objectContaining(input: unknown): ZodType;
11
- /**
12
- * @param {unknown} actual - The value we're testing.
13
- * @param {unknown} expected - The schema we're testing against.
14
- * @returns {void}
15
- */
16
- export function assertSchema(actual: unknown, expected: unknown): void;
17
- export * from "zod";
18
- import { ZodType } from 'zod';