mirror of
https://github.com/goldbergyoni/nodebestpractices.git
synced 2025-10-27 10:55:55 +08:00
Merge pull request #946 from rluvaton/patch-5
docs: convert var to const
This commit is contained in:
@ -11,7 +11,7 @@ Defensive programming is an approach to improve software and source code, in ter
|
||||
### Code example: validating complex JSON input using ‘Joi’
|
||||
|
||||
```javascript
|
||||
var memberSchema = Joi.object().keys({
|
||||
const memberSchema = Joi.object().keys({
|
||||
password: Joi.string().regex(/^[a-zA-Z0-9]{3,30}$/),
|
||||
birthyear: Joi.number().integer().min(1900).max(2013),
|
||||
email: Joi.string().email()
|
||||
|
||||
Reference in New Issue
Block a user