summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorRory& <root@rory.gay>2025-06-03 19:09:31 +0200
committerRory& <root@rory.gay>2025-06-03 19:10:57 +0200
commitf18d6fb944448c01734f409470072a3dfda2db47 (patch)
tree65947a671a0136a3936fa7b5b617821e8a831e99 /src
parentFix logRequests option (diff)
downloadnodejs-final-assignment-f18d6fb944448c01734f409470072a3dfda2db47.tar.xz
Clean up pointless error handling, coerce booleans to string in nix
Diffstat (limited to 'src')
-rw-r--r--src/dto/auth/RegisterDto.js11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/dto/auth/RegisterDto.js b/src/dto/auth/RegisterDto.js

index 40f1959..fa319b2 100644 --- a/src/dto/auth/RegisterDto.js +++ b/src/dto/auth/RegisterDto.js
@@ -22,15 +22,6 @@ export class RegisterDto { } } - try { - return await RegisterDto.schema.validateAsync(obj); - } catch (e) { - console.log(e); - throw new SafeNSoundError({ - errCode: 'JOI_VALIDATION_ERROR', - message: e.message, - validation_details: e.details - }); - } + return await RegisterDto.schema.validateAsync(obj); } }