core: 修复problem_edit中dump出错问题

This commit is contained in:
undefined committed 2020-09-06 17:18:30 +08:00
1 parent 79362ce849
commit e7428c8f79
2 files changed
+3 -3

No files matched your search

+2 -2
View File
@@ -347,8 +347,8 @@ class ProblemSettingsHandler extends ProblemManageHandler {
[this.pdoc.title, 'problem_detail', { pid }, true],
['problem_settings', null],
];
if (this.response.body.config) {
this.response.body.config = yaml.safeDump(this.response.body.config);
if (this.response.body.pdoc.config) {
this.response.body.pdoc.config = yaml.safeDump(this.response.body.pdoc.config);
}
}