Skip to content

Commit

Permalink
commented out code removed
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeffrey Wood authored and 7db9a committed Nov 3, 2023
1 parent 622ae96 commit 8287def
Showing 1 changed file with 0 additions and 32 deletions.
32 changes: 0 additions & 32 deletions server/db/Models/Repo.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,37 +43,5 @@ const initialBalance = async (Repo) => {
});
};

const unFreeze = async (Repo) => {
// const frozen = await PullRequest.findAll({
// where: { repo_id: repo.repo_id, state: "frozen" },
// });
// for (let i = 0; i < frozen.length; i++) {
// if (
// frozen[i].dataValues.yesTokenAmount === 0 &&
// frozen[i].dataValues.noTokenAmount === 0
// ) {
// console.log("frozen vote pr", frozen[i]);
// console.log("frozen vote pr", frozen[i].dataValues);
// console.log("frozen vote pr", frozen[i].dataValues.id);
// await PullRequest.update({
// state: "vote",
// where: { id: frozen[i].dataValues.id },
// });
// } else {
// console.log("frozen pre open pr", frozen[i]);
// await PullRequest.update({
// state: "pre-open",
// where: { id: frozen[i].dataValues.id },
// });
// }
// }
console.log(Repo)
}

Repo.afterBulkUpdate(console.log('#> after bulk update'), unFreeze)
Repo.afterUpdate(console.log('#> after update'), unFreeze)
Repo.beforeUpdate(console.log('#> before update'), unFreeze)


Repo.afterCreate(initialBalance);
module.exports = Repo;

0 comments on commit 8287def

Please sign in to comment.