New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@adonisjs/validator

Package Overview
Dependencies
Maintainers
1
Versions
82
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@adonisjs/validator - npm Package Compare versions

Comparing version 4.0.9 to 5.0.0

20

CHANGELOG.md

@@ -0,1 +1,21 @@

<a name="5.0.0"></a>
# [5.0.0](https://github.com/adonisjs/adonis-validation-provider/compare/v4.0.9...v5.0.0) (2018-01-31)
### Bug Fixes
* **package:** update [@adonisjs](https://github.com/adonisjs)/generic-exceptions to version 2.0.0 ([#35](https://github.com/adonisjs/adonis-validation-provider/issues/35)) ([053f6ef](https://github.com/adonisjs/adonis-validation-provider/commit/053f6ef))
### Chores
* **package:** update indicative to 5.0. ([99dfe94](https://github.com/adonisjs/adonis-validation-provider/commit/99dfe94))
### BREAKING CHANGES
* **package:** one must use the formatters directly over defining the string reference
<a name="4.0.9"></a>

@@ -2,0 +22,0 @@ ## [4.0.9](https://github.com/adonisjs/adonis-validation-provider/compare/v4.0.8...v4.0.9) (2018-01-18)

12

package.json
{
"name": "@adonisjs/validator",
"version": "4.0.9",
"version": "5.0.0",
"description": "Validator for adonis framework",

@@ -18,8 +18,8 @@ "main": "index.js",

"dependencies": {
"@adonisjs/generic-exceptions": "^1.0.0",
"indicative": "^3.0.6",
"@adonisjs/generic-exceptions": "^2.0.0",
"indicative": "^5.0.2",
"lodash": "^4.17.4"
},
"devDependencies": {
"@adonisjs/ace": "^4.0.7",
"@adonisjs/ace": "^4.0.8",
"@adonisjs/fold": "^4.0.5",

@@ -30,5 +30,5 @@ "@adonisjs/sink": "^1.0.13",

"cz-conventional-changelog": "^2.1.0",
"japa": "^1.0.5",
"japa": "^1.0.6",
"japa-cli": "^1.0.1",
"nyc": "^11.3.0",
"nyc": "^11.4.1",
"standard": "^10.0.3"

@@ -35,0 +35,0 @@ },

@@ -32,3 +32,3 @@ 'use strict'

*
* @param {Array} options.messages
* @param {Array} options.messages
* @param {Object} options.request

@@ -71,2 +71,2 @@ * @param {Object} options.response

module.exports = { ValidationException }
module.exports = { ValidationException, InvalidArgumentException: GE.InvalidArgumentException }

@@ -62,3 +62,3 @@ 'use strict'

*/
_.merge(data, sanitizedData)
request.body = _.merge({}, data, sanitizedData)
}

@@ -65,0 +65,0 @@

@@ -78,2 +78,3 @@ 'use strict'

}
return this

@@ -99,2 +100,3 @@ }

}
return this

@@ -101,0 +103,0 @@ }

@@ -13,4 +13,5 @@ 'use strict'

const indicative = require('indicative')
const Validation = require('../Validation')
const { ValidationException } = require('../Exceptions')
const { ValidationException, InvalidArgumentException } = require('../Exceptions')

@@ -25,4 +26,9 @@ module.exports = {

formatters: indicative.formatters,
extend: indicative.extend,
extend: function (rule, fn) {
if (typeof (fn) !== 'function') {
throw InvalidArgumentException.invalidParameter('Validator.extend expects 2nd parameter to be a function', fn)
}
indicative.validations[rule] = fn
},
ValidationException
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc