Download pool/shard005/JavaScript/0031158_error.js from Variable-role/sajaniemi_variable_dataset_large: direct link, hf CLI and curl.
- Browser
- Download file 822 Bytes
-
https://huggingface.co/datasets/Variable-role/sajaniemi_variable_dataset_large/resolve/main/pool/shard005/JavaScript/0031158_error.js
- Command line
-
hf download hf://datasets/Variable-role/sajaniemi_variable_dataset_large/pool/shard005/JavaScript/0031158_error.js
-
curl -L -o 0031158_error.js https://huggingface.co/datasets/Variable-role/sajaniemi_variable_dataset_large/resolve/main/pool/shard005/JavaScript/0031158_error.js
822 Bytes
| ; | |
| const _errors = require('./../application/errors.json'); | |
| class NotAuthorizedError{ | |
| constructor(message) { | |
| this.name = 'TRXNTA'; | |
| this.message = message || _errors['TRXNTA'].message; | |
| } | |
| } | |
| class ForbiddenError{ | |
| constructor(message) { | |
| this.name = 'TRXFBD'; | |
| this.message = message || _errors['TRXFBD'].message; | |
| } | |
| } | |
| class EnvironmentError { | |
| constructor(code) { | |
| if(!_errors[code]) code = 'ENX000'; | |
| this.name = code; | |
| this.message = _errors[code].message; | |
| } | |
| } | |
| class BusinessError { | |
| constructor(code) { | |
| if(!_errors[code]) code = 'ENX000'; | |
| this.name = code; | |
| this.message = _errors[code].message; | |
| } | |
| } | |
| module.exports = { | |
| BusinessError : BusinessError, | |
| EnvironmentError : EnvironmentError, | |
| ForbiddenError : ForbiddenError, | |
| NotAuthorizedError : NotAuthorizedError | |
| }; |