drudge / mongoose-timestamp

Adds createdAt and updatedAt date attributes that get auto-assigned to the most recent create/update timestamp
Other
308 stars 64 forks source link

Fixed hard coded bson module location #5

Closed inxilpro closed 11 years ago

inxilpro commented 11 years ago

The code currently loads bson from 'mongoose/node_modules/mongodb/node_modules/bson' which assumes that mongoose is installed in mongoose-timestamp's node_modules directory, and that mongodb is installed under mongoose's node_modules directory. Better to set bson as a dependency and load it directly, since those two things are not always true.

Also, mongoose is really not a dependency at all. You were just loading it to get access to bson. You only need it for tests.