Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature(common): add transformOptions to ValidationPipeOptions #1418

Merged
merged 4 commits into from
Jan 16, 2019

Conversation

FionaLovett
Copy link
Contributor

allows plainToClass to expose class properties to defined groups as per issue #1374

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

[ ] Bugfix
[ x ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Other... Please describe:

What is the current behavior?

plainToClass has no facility for following rules in Expose decorators regarding groups

Issue Number: 1374

What is the new behavior?

a new property "transformOptions" on the ValidationPipeOptions class is passed into plainToClass so that classes are transformed according to the groups provided.

Does this PR introduce a breaking change?

[ ] Yes
[ x ] No

Other information

allows plainToClass to expose class properties to defined groups as per issue nestjs#1374
@kamilmysliwiec
Copy link
Member

kamilmysliwiec commented Jan 2, 2019

It seems that tests are failing (see Travis output). Thanks for the contribution!

allows plainToClass to expose class properties to defined groups as per issue nestjs#1374
@FionaLovett
Copy link
Contributor Author

Yes, sorry, couldn't run them locally. Got it fixed now, trying to create a new PR. Newbie here!

allows plainToClass to expose class properties to defined groups as per issue nestjs#1374
allows plainToClass to expose class properties to defined groups as per issue nestjs#1374
@coveralls
Copy link

coveralls commented Jan 2, 2019

Pull Request Test Coverage Report for Build 1358

  • 3 of 3 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.003%) to 93.777%

Totals Coverage Status
Change from base Build 1339: 0.003%
Covered Lines: 2853
Relevant Lines: 2976

💛 - Coveralls

@kamilmysliwiec kamilmysliwiec modified the milestones: 5.5.1, 5.6.0 Jan 14, 2019
@kamilmysliwiec
Copy link
Member

LGTM

@kamilmysliwiec kamilmysliwiec merged commit 94679b2 into nestjs:master Jan 16, 2019
@lock
Copy link

lock bot commented Sep 24, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Sep 24, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants