From dfa1e52a16af12b56e02c899e36e60607ef1b1d0 Mon Sep 17 00:00:00 2001 From: Boon Hian Date: Sat, 24 Feb 2024 14:44:03 +0800 Subject: [PATCH] chore: remove unused ranking model --- apps/challenges/src/model/ranking.ts | 34 ----------------------- apps/challenges/src/model/rankingScore.ts | 2 -- 2 files changed, 36 deletions(-) delete mode 100644 apps/challenges/src/model/ranking.ts diff --git a/apps/challenges/src/model/ranking.ts b/apps/challenges/src/model/ranking.ts deleted file mode 100644 index 02168cc8..00000000 --- a/apps/challenges/src/model/ranking.ts +++ /dev/null @@ -1,34 +0,0 @@ -import mongoose, {Schema} from 'mongoose'; - -export interface RankingModel { - _id: mongoose.Types.ObjectId; - userID: mongoose.Types.ObjectId; - seasonID: mongoose.Types.ObjectId; - points: number; - createdAt: Date; - updatedAt: Date; -} - -const seasonSchema: Schema = new Schema({ - userID: { - type: mongoose.Schema.Types.ObjectId, - required: true, - ref: 'User' - }, - seasonID: { - type: mongoose.Schema.Types.ObjectId, - required: true, - ref: 'Season' - }, - points: { - type: Number, - required: [true, 'Please add a points value'] - } -}, { - timestamps: true -}); - - -const Ranking = mongoose.model('Ranking', seasonSchema); - -export { Ranking as default } diff --git a/apps/challenges/src/model/rankingScore.ts b/apps/challenges/src/model/rankingScore.ts index 88cec8a6..dbd0b4e5 100644 --- a/apps/challenges/src/model/rankingScore.ts +++ b/apps/challenges/src/model/rankingScore.ts @@ -1,5 +1,3 @@ -import mongoose, {Schema} from 'mongoose'; - export interface UserRanking { user: { userID: string;