Skip to content
This repository has been archived by the owner on Mar 21, 2023. It is now read-only.

Commit

Permalink
Update attemptTest.js
Browse files Browse the repository at this point in the history
  • Loading branch information
0x0is1 committed Nov 27, 2022
1 parent 0dbab9e commit 03306df
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/attemptTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,17 @@ async function getAnswer(rno) {
else selid = 1;

var set = prompt('Enter set number: ');
var attempt4me = prompt("Attempt this test for you? [y/n]: ")
var attempt4me = parseInt(prompt("Attempt this test for you? [y/n]: "));
if (attempt4me != "y") {
reg_no = 12114441; // reg no to attempt, retired ofcourse
}
var tid = data[selid-1].TestId;
var currScore = 0;

// getting current score
await parseOAS.fetch_result(tid, reg_no).then(redata => {
currScore = parseInt(redata[0].MarksObtained);
});
//await parseOAS.fetch_result(tid, reg_no).then(redata => {
//currScore = parseInt(redata[0].MarksObtained);
//});

await parseOAS.fetch_qids(tid, set).then(async qiddata => {
for (let [idx, i] of qiddata.entries()) {
Expand Down Expand Up @@ -65,4 +65,4 @@ async function getAnswer(rno) {

module.exports = {
getAnswer
};
};

0 comments on commit 03306df

Please sign in to comment.