toonvanstrijp / nestjs-i18n

The i18n module for nestjs.
https://nestjs-i18n.com
Other
656 stars 113 forks source link

for people who face: typeerror: cannot read properties of undefined (reading 'pipe') #623

Closed delai closed 2 months ago

delai commented 8 months ago

Describe the bug

add

    if (value.constructor.name === 'I18nContext') {
      return value
    }

at the beginning of the transform function in your ValidationPipe like this

image

Reproduction

@I18n() i18n: I18nContext

System Info

@I18n() i18n: I18nContext

Used Package Manager

npm

Validations