Skip to content

Commit f15aeef

Browse files
author
Sergey Dolin
committed
v 1.0.9 fix set virtual
1 parent 5ce4c68 commit f15aeef

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

index.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,8 @@ var prototype_mongoose=function(mongoose_instance,_currentLocale,_locales){
111111
if (l) return this.get(vpath+'.'+l);
112112
return undefined;
113113
}).set(function(value,virtual){
114-
if (currentLocale(value))
114+
var l=currentLocale();
115+
if (l)
115116
this.set((prefix?prefix:'')+key+'.'+l,value);
116117
});
117118
}else{

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
],
66
"name": "mongoose-localize",
77
"description": "A module to convert mongoose model property to set of localized properties.",
8-
"version": "1.0.8",
8+
"version": "1.0.9",
99
"keywords": [
1010
"mongoose",
1111
"localize",

0 commit comments

Comments
 (0)