Browse Source

S => s

pull/6/head
t123yh 7 years ago
parent
commit
559b434f86
  1. 4
      models/rating_calculation.js
  2. 2
      models/rating_history.js

4
models/rating_calculation.js

@ -54,7 +54,7 @@ class RatingCalculation extends Model {
return newItem;
}
async loadRelationShips() {
async loadRelationships() {
this.contest = await Contest.fromID(this.contest_id);
}
@ -66,7 +66,7 @@ class RatingCalculation extends Model {
rating_calculation_id: this.rating_calculation_id
});
for (const history of histories) {
await history.loadRelationShips();
await history.loadRelationships();
const user = history.user;
await history.destroy();
const ratingItem = (await RatingHistory.findOne({

2
models/rating_history.js

@ -68,7 +68,7 @@ class RatingHistory extends Model {
return newRecord;
}
async loadRelationShips() {
async loadRelationships() {
this.user = await User.fromID(this.user_id);
}

Loading…
Cancel
Save