From b48d1ba7ce5e91fd56a9f96c6d70a0257b42c092 Mon Sep 17 00:00:00 2001 From: Talysson de Oliveira Cassiano Date: Mon, 16 Sep 2019 10:59:35 -0300 Subject: [PATCH] Bump minor to 1.8.0 (#99) --- CHANGELOG.md | 4 ++++ dist/structure.js | 2 +- package.json | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 33a9a74..5430142 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## 1.8.0 - 2019-09-16 +Enhancements: +* Add `unique` validation to arrays + ## 1.7.0 - 2019-09-14 Enhancements: * Add method to clone structures diff --git a/dist/structure.js b/dist/structure.js index 82fa32b..f2d3b18 100644 --- a/dist/structure.js +++ b/dist/structure.js @@ -602,7 +602,7 @@ return /******/ (function(modules) { // webpackBootstrap var _require = __webpack_require__(10), mapToJoi = _require.mapToJoi; - var joiMappings = [['minLength', 'min', true], ['maxLength', 'max', true], ['exactLength', 'length', true]]; + var joiMappings = [['minLength', 'min', true], ['maxLength', 'max', true], ['exactLength', 'length', true], ['unique', 'unique']]; module.exports = function arrayValidation(typeDescriptor, itemTypeDescriptor) { var joiSchema = joi.array().items(itemTypeDescriptor.validation); diff --git a/package.json b/package.json index 0e4230e..cd57185 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "structure", - "version": "1.7.0", + "version": "1.8.0", "description": "A simple schema/attributes library built on top of modern JavaScript", "main": "src/index.js", "browser": "dist/structure.js",