Skip to content

Commit

Permalink
Fix self-sim bug
Browse files Browse the repository at this point in the history
  • Loading branch information
zhouziqunzzq authored and VOID001 committed Jul 31, 2018
1 parent 09cbf69 commit 578a6dd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/Http/Controllers/RESTController.php
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,9 @@ public function checkSIM($run_id)
'pid' => $currentSubmissionObj->pid,
'lang' => $currentSubmissionObj->lang,
'result' => "Accepted"
])->get();
])
->where('uid', '<>', $currentSubmissionObj->uid) //Don check submissions submitted by the same uid
->get();

$lang = $currentSubmissionObj->lang;
$max_similarity = 0;
Expand Down

0 comments on commit 578a6dd

Please sign in to comment.