Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ Not seeking contribution at this time.
## Authors

- **Ernest Phillips** -
Collaborated with @erndevelops

## License

Expand Down
16 changes: 16 additions & 0 deletions app/workout/workout.model.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,21 @@ workoutSchema.methods.serialize = function() {
const Workout = mongoose.model("workout", workoutSchema);

const WorkoutJoiSchema = Joi.object().keys({
<<<<<<< HEAD
user: Joi.string().optional(),
exercise: Joi.string()
.min(1)
.required(),
reps: Joi.number()
.min(1)
.required(),
<<<<<<< HEAD
weight: Joi.number().min(1)
=======
weight: Joi.number().min(1),
date: Joi.date()
>>>>>>> c67b88e6bca7463a4270d6b72836ffa09870c8f9
=======
user: Joi.string().required(),
sets: Joi.object({
exercise: Joi.string(),
Expand All @@ -65,6 +80,7 @@ const WorkoutJoiSchema = Joi.object().keys({
weight: Joi.number()
}),
date: Joi.date().min('1-1-1980')
>>>>>>> master
});

module.exports = {
Expand Down
4 changes: 3 additions & 1 deletion start.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@ const {
startServer
} = require('./app/server');

startServer();
startServer();

//HEre is a comment from @erndevelops