mongoose-url-slugs
Advanced tools
Comparing version 0.1.1 to 0.1.2
@@ -106,2 +106,7 @@ var extend = require('extend'); | ||
if (!newSlug.length && options.index_sparse) { | ||
doc.set(options.field, undefined); | ||
return next(); | ||
} | ||
if (options.maxLength) newSlug = newSlug.substr(0, options.maxLength); | ||
@@ -108,0 +113,0 @@ |
@@ -9,3 +9,3 @@ { | ||
"description": "Create URL compatiable slugs on mongoose models, ensuring uniqueness.", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"keywords": [ | ||
@@ -12,0 +12,0 @@ "mongoose slugs", |
@@ -74,2 +74,3 @@ [![Build Status](https://travis-ci.org/mindblaze/mongoose-url-slugs.png?branch=master)](https://travis-ci.org/mindblaze/mongoose-url-slugs) | ||
## History | ||
* v0.1.2 (2014-12-09) -- Fixed an issue with index_sparse. | ||
* v0.1.1 (2014-12-09) -- Fixed an issue due to maxLength. | ||
@@ -76,0 +77,0 @@ * v0.1.0 (2014-11-28) -- Added index_sparse, maxLength options. |
10433
102
106