Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am paglias on github.
  • I am paglias (https://keybase.io/paglias) on keybase.
  • I have a public key ASBwbTfaTnIFhnrC5QVG63_6zF-Dhr9WV8LqW8_G__Lumwo

To claim this, I am signing this object:

{
"name": "mongoose-dictionary-testing",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"private": true,
"dependencies": {
module.exports = function(mongoose){
// Sub document to be used inside the dictionary
var DictionarySubDocument = require('./dictionarySubDocument')(mongoose);
function SchemaDictionary(path, options){
if(
!options ||
!options.schema ||
// TODO Do not support object with no schemas (mixed)
@paglias
paglias / index.js
Created September 9, 2014 21:28
Mongoose 3.9.1/3.8.15 Koa bug
var koa = require('koa'),
app = koa();
var mongoose = require('mongoose');
mongoose.connect('mongodb://localhost/koa-mongoose-bug');
mongoose.connection.on('error', function(){});
var aSchema = mongoose.Schema({
title: String
});