<commit_before>import mongoose from 'mongoose';
import { Promise } from 'es6-promise';
mongoose.Promise = Promise;
import findOrCreate from 'mongoose-findorcreate';

const Schema = mongoose.Schema;

const TripSchema = new Schema( {
  userId: { type: String, required: true },
  lastUpdated: { type: Date, required: true },
  tripLocations: [ { type: mongoose.Schema.Types.ObjectId, ref: 'Location' } ],
} );

TripSchema.plugin( findOrCreate );

export default mongoose.model( 'Trip', TripSchema );
<commit_msg>Give a default date to Trip.lastUpdated<commit_after>import mongoose from 'mongoose';
import { Promise } from 'es6-promise';
mongoose.Promise = Promise;
import findOrCreate from 'mongoose-findorcreate';

const Schema = mongoose.Schema;

const TripSchema = new Schema( {
  userId: { type: String, required: true },
  lastUpdated: { type: Date, default: Date.now, required: true },
  tripLocations: [ { type: mongoose.Schema.Types.ObjectId, ref: 'Location' } ],
} );

TripSchema.plugin( findOrCreate );

export default mongoose.model( 'Trip', TripSchema );

{'fraction_non_alphanumeric': 0.1295774647887324, 'fraction_numerical': 0.0018779342723004694, 'mean_word_length': 5.270588235294118, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6842157', 'n_tokens_mistral': 335, 'n_tokens_neox': 344, 'n_words': 93}