Permalink
Browse files

Adding in spaces so Michael Sorrentino isn't MichaelSorrentino.

  • Loading branch information...
1 parent 8629b1d commit 61b9c10d0fce7977101c9e0b587edd0dc6e56b8a @grahamc grahamc committed Jun 27, 2011
Showing with 3 additions and 3 deletions.
  1. +3 −3 docs/virtuals.md
View
6 docs/virtuals.md
@@ -31,7 +31,7 @@ To do so, you can declare a virtual attribute on the Schema, `Person`:
PersonSchema.virtual('name.full')
.get( function () {
- return this.name.first + this.name.last;
+ return this.name.first + ' ' + this.name.last;
});
So when you get `name.full`, via
@@ -41,7 +41,7 @@ So when you get `name.full`, via
the implementation ends up invoking the getter function
function () {
- return this.name.first + this.name.last;
+ return this.name.first + ' ' + this.name.last;
}
and returning it.
@@ -54,7 +54,7 @@ Mongoose allows you to do this, too, via virtual attribute setters. You can defi
PersonSchema.virtual('name.full')
.get( function () {
- return this.name.first + this.name.last;
+ return this.name.first + ' ' + this.name.last;
})
.set( function (setFullNameTo) {
var split = setFullNameTo.split(' ')

0 comments on commit 61b9c10

Please sign in to comment.