Commit Graph

27 Commits

Author SHA1 Message Date
Kamil Mysliwiec
a69109ee19 Merge branch '8.0.0' into fix-set-name-property-of-exception-object-equal-to-class-name 2021-01-27 12:09:34 +01:00
Maciej Sikorski
ec9727093d feat: allow to config cors async
Bump version of the fastify-cors.
Add CorsOptionsDelegate interface.
Add CorsOptionsDelegate as an acceptable type
for every enableCors usage.

Closes nestjs/nest#6118
2021-01-25 22:46:11 +01:00
Karan Gupta
e54c0e1c79 fix(common): set name of httpexception as class name
Added a method to set name property of exception object equal to class name which currently is always Error. Updated tests.

Closes #5809
2020-12-04 14:18:28 +05:30
Karan Gupta
26609840a4 fix(common): set name of httpexception as class name
Added a method to set name property of exception object equal to class name which currently is always Error

Closes #5809
2020-12-04 11:50:18 +05:30
Roberto Huertas
d429a068b4 refactor(common): change names of createBody arguments
This PR just changes the names of some of the `createBody` method parameters to be consistent with
the names of the parameters used by some of the `HttpException` subclasses.
2020-11-16 20:47:33 +01:00
Kamil Myśliwiec
ed46d6c618 fix(core): invalid arguments order, fix message key (http exceptions) 2020-03-15 14:03:07 +01:00
Saulo
221a103ecd refactor(common): fix exceptions doc/var names
Fix incorrect documentation strings for HTTP exceptions
and a few variable names.

Closes #4042
2020-03-10 15:29:53 -03:00
Kamil Myśliwiec
5abbc005a4 fix(): minor updates 2020-03-03 17:26:52 +01:00
Kamil Myśliwiec
dece70c319 fix(common): standarize exceptions that inherit from http exception 2020-03-03 14:54:24 +01:00
Kamil Mysliwiec
ad6461b930 Merge pull request #4045 from saulotoledo/standardizes_http_exceptions_output
fix(common): standardizes http exceptions output
2020-03-02 17:11:14 +01:00
Kamil Myśliwiec
8e78fdb266 enhancement() improve message property of http exceptions 2020-03-02 14:39:49 +01:00
Kamil Myśliwiec
73de9cb0a8 refactor(core) make message property (http errors) serializable 2020-03-02 14:39:49 +01:00
Saulo
c5ceb933d9 fix(common): standardizes http exceptions output
Originally, the default output of HTTPException is {statusCode,
message}, but the default output for another specific exception
(e.g., BadRequestException) is {statusCode, error}. These changes
make them behave consistently.

Closes #4044
2020-02-12 00:47:16 +01:00
Kamil Myśliwiec
489d3299c0 format() run prettier, update format script 2019-10-04 09:08:27 +02:00
John Biundo
10c9d66cc4 feat(common): Add documentation for public API 2019-08-26 22:18:04 +02:00
Ivan Veselin
e91b711456 feature(common) move createResponseBody to HttpException
renamed and moved createResponseBody function to be exported as a part
of HttpException

Closes #2727
2019-08-22 15:35:47 +02:00
Kamil Myśliwiec
41e4e853f6 refactor(): adjust to the codebase guidelines 2019-07-09 15:13:26 +02:00
Chris Sidell
987012610d Address styling concerns 2019-07-04 10:51:01 -07:00
csidell-earny
8a80de3017 Add typing target for getErrorString 2019-07-04 10:45:28 -07:00
Chris Sidell
fd8e490d34 Fix linting error 2019-07-03 18:37:20 -07:00
Chris Sidell
40cd722eaf Change name to not collide with duplicate definition in RpcException 2019-07-03 18:22:08 -07:00
Chris Sidell
724ddd8d23 Make errors serializable by default 2019-07-03 18:11:42 -07:00
Konrad Cerny
547615afd7 bugfix(common): fix breaking change on http exception 2019-04-10 11:38:36 +02:00
Kamil Myśliwiec
ca62dc951d bugfix(common): http exceptions should have the same stacktrace as generic 2019-03-27 10:38:14 +01:00
Alexandru Furculita ♻
b47a384621 Update http.exception.ts 2018-04-19 14:21:02 +03:00
Alexandru Furculita ♻
e842768bb1 Update http.exception.ts
Some remains from a git merge/rebase conflict
2018-04-19 14:20:22 +03:00
Kamil Myśliwiec
614de27310 refactor(@nestjs) rename directories, add script, fix tests 2018-03-24 15:11:48 +01:00