text: // Create the required custom methods at the bottom of this file
  
  const mongoose = require("mongoose");
  
  const Schema = mongoose.Schema;
  
  const UserSchema = new Schema({
    firstName: {
      type: String,
      trim: true,
      required: "First Name is Required"
    },
  
    lastName: {
      type: String,
      trim: true,
      required: "Last Name is Required"
    },
  
    username: {
      type: String,
      trim: true,
      required: "Username is Required"
    },
  
    password: {
      type: String,
      trim: true,
      required: "Password is Required",
      validate: [
        ({length}) => length >= 6,
        "Password should be longer."
      ]
    },
  
    email: {
      type: String,
      unique: true,
      match: [/.+@.+\..+/, "Please enter a valid e-mail address"]
    },
  
    userCreated: {
      type: Date,
      default: Date.now
    },
  
    lastUpdated: Date,
  
    fullName: String
  });
  
  // setFullName: sets the current user's `fullName` property to their lastName appended to their `firstName`
  
  // lastUpdatedDate: sets the current user's `lastUpdated` property to Date.now()
  
  // This creates our model from the above schema, using mongoose's model method
  const User = mongoose.model("User", UserSchema);
  
  // Export the User model
  module.exports = User;
  