diff --git a/modules/submission.js b/modules/submission.js index 15f061b..d029602 100644 --- a/modules/submission.js +++ b/modules/submission.js @@ -123,7 +123,6 @@ app.get('/submissions', async (req, res) => { await judge_state.forEachAsync(async obj => { await obj.loadRelationships(); - if (obj.problem.type !== 'submit-answer') obj.code_length = Buffer.from(obj.code).length; }); res.render('submissions', { @@ -174,8 +173,6 @@ app.get('/submission/:id', async (req, res) => { await judge.loadRelationships(); if (judge.problem.type !== 'submit-answer') { - judge.code_length = Buffer.from(judge.code).length; - let key = syzoj.utils.getFormattedCodeKey(judge.code, judge.language); if (key) { let formattedCode = await FormattedCode.findOne({