core: fix pretest

This commit is contained in:
undefined committed 2021-05-31 15:27:09 +08:00
1 parent b6441b853b
commit 8a647dc36a
7 files changed
+30 -23

No files matched your search

@@ -37,10 +37,11 @@ const mapDispatchToProps = (dispatch) => ({
});
},
postPretest(props) {
const req = request.post(UiContext.postPretestUrl, {
const req = request.post(UiContext.postSubmitUrl, {
lang: props.editorLang,
code: props.editorCode,
input: props.pretestInput || ' ',
pretest: true,
});
dispatch({
type: 'SCRATCHPAD_POST_PRETEST',
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/ui-default",
"version": "4.11.6",
"version": "4.11.7",
"author": "undefined <i@undefined.moe>",
"license": "AGPL-3.0",
"main": "hydro.js",
@@ -5,7 +5,6 @@
{{ set(UiContext, {
problemId: pdoc.pid|default(pdoc.docId),
problemNumId: pdoc.docId,
postPretestUrl: url('problem_pretest', pid=pdoc.docId),
codeLang: handler.user.codeLang,
codeTemplate: handler.user.codeTemplate,
pdoc: pdoc