text: var mongoose = require('mongoose');
  
  var schema = mongoose.Schema({
      title: {
          type: String,
          required: true
      },
      description: {
          type: String
      },
      question: {
          type: String
      },
      keywords: [{
          type: String
      }],
      created: {
          type: Date,
          default: Date.now
      },
      author: {
          _id: {
              type: mongoose.Schema.Types.ObjectId, 
              ref: 'User'
          },
          username: {
              type: String
          },
          link: {
              rel: {
                  type: String
              },
              href: {
                  type: String
              }
          }
      },
      link: {
          rel: {
              type: String
          },
          href: {
              type: String
          }
      },
      isPublic: {
          type: Boolean,
          default: true
      },
      versions: [
          {
              _id: {
                  type: mongoose.Schema.Types.ObjectId, 
                  ref: 'MapContent'
              },
              version: {
                  type: Number
              },
              link: {
                  rel: {
                      type: String
                  },
                  href: {
                      type: String
                  }
              }
          }
      ]
  }, { usePushEach: true });
  
  mongoose.model('Map', schema);
  