diff --git a/webapp/templates/team/partials/submit_scripts.html.twig b/webapp/templates/team/partials/submit_scripts.html.twig index bf0bdb1af6..cd280d2627 100644 --- a/webapp/templates/team/partials/submit_scripts.html.twig +++ b/webapp/templates/team/partials/submit_scripts.html.twig @@ -16,7 +16,10 @@ } } - function maybeShowEntryPoint(filename) { + function maybeShowEntryPoint() { + let filename = $('#submit_problem_code').val() ?? ''; + filename = filename.replace(/^.*[\\\/]/, ''); + var langid = $('#submit_problem_language').val(); if (langid === "") { return; @@ -80,7 +83,7 @@ } } - maybeShowEntryPoint(filename); + maybeShowEntryPoint(); // Problem ID