1748 Commits

Author SHA1 Message Date
Kamil Myśliwiec
5d31df7eb6 chore(release): publish v11.1.14 release 2026-02-17 17:24:39 +01:00
Kamil Mysliwiec
829d326727 Merge pull request #16314 from SpencerKaiser/bugfix/cors-types
fix(common): change requestOrigin type
2026-02-06 12:06:34 +01:00
Spencer Kaiser
5058600ae3 fix(common): change requestOrigin type
fix(common): change requestOrigin type
2026-02-04 20:48:36 -06:00
JulienDuf
91212b20d3 fix: return type error 2026-02-04 16:01:55 -05:00
JulienDuf
804d27bbe4 fix: invalid context when no stack trace is provided 2026-02-04 14:20:21 -05:00
Kamil Myśliwiec
8d1c16c1ca chore: update readme 2026-02-03 14:07:38 +01:00
Kamil Myśliwiec
e3a958ac3e chore(release): publish v11.1.13 release 2026-02-03 13:47:36 +01:00
Lee Donghyun
d88856c3fa test(common): add unit tests for class serializer interceptor
Add comprehensive unit tests for ClassSerializerInterceptor which
previously had no test coverage despite being a public API.

Test coverage includes:
- constructor with custom transformer package injection
- intercept() with RxJS pipe and context options merging
- serialize() for arrays, objects, and StreamableFile handling
- transformToPlain() with type conversion and instanceOf checks
- getContextOptions() with metadata precedence (handler > class)
- Edge cases: null/undefined, mixed arrays, Date objects, primitives

Total: 25+ test cases covering all public methods and edge cases.
2026-01-26 00:38:25 +09:00
Kamil Mysliwiec
a1f6162971 Merge pull request #16202 from som14062005/fix/issue-16195
fix(common): exclude built-in primitives from strip proto keys
2026-01-23 09:44:35 +01:00
som14062005
82226347fd refactor: move built-in types to module-level constant 2026-01-21 19:42:22 +05:30
neo
979a8e2f04 fix(common): Fix skipping maxArrayLength and maxStringLength option
Fixes #16229
2026-01-21 16:00:28 +09:00
som14062005
8fb17f517c fix(common): exclude built-in primitives from strip proto keys
Skip constructor deletion for Date, RegExp, Error, Map, Set, WeakMap, and WeakSet to fix Jest useFakeTimers compatibility. Maintains prototype pollution protection for regular objects.

Fixes #16195
2026-01-16 02:00:15 +05:30
som14062005
16296b9ce8 fix(common): exclude built-in primitives from strip proto keys
Skip constructor deletion for Date, RegExp, Error, Map, Set, WeakMap, and WeakSet to fix Jest useFakeTimers compatibility. Maintains prototype pollution protection for regular objects.

Fixes #16195
2026-01-15 21:30:09 +05:30
Kamil Myśliwiec
96932ad073 chore(release): publish v11.1.12 release 2026-01-15 09:29:44 +01:00
iamkanguk97
a52e60820e fix(common): convert absolute paths to urls for esm loading
Uses pathToFileURL to convert file system paths to proper URLs
before passing to the ESM loader, ensuring cross-platform compatibility.

Fixes #16179
2026-01-12 00:05:45 +09:00
renovate[bot]
8a5be22e94 fix(deps): update dependency file-type to v21.3.0 2026-01-04 01:44:43 +00:00
Kamil Myśliwiec
585f55f0e4 chore: revert lerna version 2025-12-29 14:30:25 +01:00
Kamil Myśliwiec
fef323b2c9 chore(release): publish v11.1.11 release 2025-12-29 14:26:08 +01:00
dependabot[bot]
a4a50d4fc4 chore(deps): bump file-type from 21.1.1 to 21.2.0
Bumps [file-type](https://github.com/sindresorhus/file-type) from 21.1.1 to 21.2.0.
- [Release notes](https://github.com/sindresorhus/file-type/releases)
- [Commits](https://github.com/sindresorhus/file-type/compare/v21.1.1...v21.2.0)

---
updated-dependencies:
- dependency-name: file-type
  dependency-version: 21.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-26 00:01:55 +00:00
Kamil Myśliwiec
de5e0262d2 chore(@nestjs) publish v11.1.10 release 2025-12-22 09:31:35 +01:00
Kamil Mysliwiec
fd46a65dc8 Merge branch 'master' into fix/file-type-validator-esm-error 2025-12-21 18:24:01 +01:00
Kamil Mysliwiec
4da3e2ce0f Update packages/common/pipes/file/file-type.validator.ts 2025-12-21 18:23:23 +01:00
Kamil Mysliwiec
cc2659aba1 Merge pull request #16060 from Jo-Minseok/feat/filevalidator-custom-message
feat(common): add message property to file type validator
2025-12-21 18:21:45 +01:00
evgeniy.chernomortsev
c97b2ce4fe fix(common): improve error handling in FileTypeValidator
Add warning logs when file-type package fails to load due to ESM
import issues. This helps users debug issues when running tests
with Jest without --experimental-vm-modules flag.

When loading fails and fallbackToMimetype is enabled, the validator
now correctly falls back to mimetype comparison instead of silently
returning false.

Closes #15055
2025-12-17 13:40:37 +04:00
J_Coder
b6aa4a2311 test(common): add tests for dynamic custom error message 2025-12-16 02:56:38 +09:00
J_Coder
6c2f2bf254 feat(common): add error message factory function and shared context type 2025-12-16 02:53:59 +09:00
Kamil Mysliwiec
f3fb0c2c44 Merge pull request #16079 from liu-jin-yi/fix/issue-16050
fix: enhance ValidationPipe to prevent prototype pollution
2025-12-15 11:40:26 +01:00
liujinyi
c995f70f02 fix: enhance ValidationPipe to prevent prototype pollution by stripping 'constructor' and 'prototype' properties 2025-12-15 16:48:53 +08:00
shash-hq
def58e0581 fix(common): handle legacy node version in file validator 2025-12-15 11:11:04 +05:30
shash-hq
bd36c2832d fix(common): resolve file-type path explicitly #15270 2025-12-15 09:08:27 +05:30
J_Coder
af671a15ed test(common): add tests for custom error message and deprecated message 2025-12-14 04:10:01 +09:00
J_Coder
f9b6026b12 refactor(common): deprecate message option and prefer error message 2025-12-14 04:04:32 +09:00
J_Coder
abe4efea62 refactor(common): rename message property to error message 2025-12-14 03:21:38 +09:00
Kamil Mysliwiec
4e28b37286 Merge pull request #16061 from giorgikakauridze/refactor/log-level-evaluation
refactor(logging): optimize isLogLevelEnabled by replacing sort with single-pass max
2025-12-13 18:00:18 +01:00
giorgikakauridze
7dd7737c07 style(logging): apply prettier formatting 2025-12-13 15:22:07 +04:00
giorgikakauridze
5d089abe46 style(logging): apply prettier formatting 2025-12-13 15:07:54 +04:00
taegwon son
af7289e4f5 test(common): Add missing tests for StreamableFile
Add tests for:
- Default error logger behavior (logger.error invocation)
- Edge case when input is neither Uint8Array nor has pipe method

Coverage: 97.06% -> 100%
2025-12-13 16:33:27 +09:00
giorgikakauridze
e6d34f06b9 refactor(logging): optimize isLogLevelEnabled by replacing sort with single-pass max 2025-12-12 23:34:39 +04:00
J_Coder
2f26b30fd9 test(common): add unit tests for file type validator 2025-12-13 02:36:34 +09:00
J_Coder
8309ddc859 feat(common): add message property to file type validator 2025-12-13 01:52:20 +09:00
J_Coder
52d30f276f docs(common): add tsdoc to max file size validator properties 2025-12-13 01:52:07 +09:00
taegwon son
d4b527f9e7 test(common): Add missing tests for StreamableFile error handling 2025-12-11 14:48:02 +09:00
Kamil Myśliwiec
0c93692bc9 chore: update prettier 2025-12-05 13:35:27 +01:00
Kamil Myśliwiec
0430f3f190 chore: resolve conflicts 2025-12-05 13:31:11 +01:00
Kamil Myśliwiec
5045fea937 chore: update eslint monorepo 2025-12-05 13:29:23 +01:00
Kamil Mysliwiec
3723412508 Merge pull request #15986 from mag123c/fix/shutdown-hooks-process-exit
feat(core): add option for async logger compatibility
2025-12-05 13:00:52 +01:00
Alvis
a4590016c3 fix(common): Support fallbackToMimetype without buffer
Allow FileTypeValidator to validate files saved on disk where no buffer is available.
Use mimetype as a fallback when fallbackToMimetype=true and buffer is missing.
Preserves existing behavior when fallbackToMimetype is not enabled.
2025-12-03 21:23:21 +08:00
mag123c
b64aef5d69 fix(core): add option for async logger compatibility 2025-11-28 22:52:38 +09:00
dependabot[bot]
ada33a1578 chore(deps): bump file-type from 21.1.0 to 21.1.1
Bumps [file-type](https://github.com/sindresorhus/file-type) from 21.1.0 to 21.1.1.
- [Release notes](https://github.com/sindresorhus/file-type/releases)
- [Commits](https://github.com/sindresorhus/file-type/compare/v21.1.0...v21.1.1)

---
updated-dependencies:
- dependency-name: file-type
  dependency-version: 21.1.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-20 00:01:36 +00:00
Kamil Myśliwiec
64c85527f5 chore(@nestjs) publish v11.1.9 release 2025-11-14 11:18:00 +01:00