Skip to content

Instantly share code, notes, and snippets.

@pajtai
Last active May 6, 2018 05:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pajtai/12340e0e8adf99a368d0a92d6e4ab802 to your computer and use it in GitHub Desktop.
Save pajtai/12340e0e8adf99a368d0a92d6e4ab802 to your computer and use it in GitHub Desktop.
'use strict';
const mongoose = require('mongoose');
module.exports = (app) => {
const tasksSchema = mongoose.Schema({
title: String,
done: {
type: Boolean,
default: false
}
});
return app.connection.model('Tasks', tasksSchema);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment