From 2f9db85ccc2a2c6d2e9d62ca8617d19590dc59a0 Mon Sep 17 00:00:00 2001 From: caishi <1149225589@qq.com> Date: Thu, 8 Dec 2022 15:08:43 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=BB=BA=E6=96=87=E4=BB=B6-=E5=8A=A0?= =?UTF-8?q?=E5=AF=86content?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/forge/Newfile/UserSubmitComponent.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/forge/Newfile/UserSubmitComponent.js b/src/forge/Newfile/UserSubmitComponent.js index 08cac8d69..5ec1fc7cf 100644 --- a/src/forge/Newfile/UserSubmitComponent.js +++ b/src/forge/Newfile/UserSubmitComponent.js @@ -4,6 +4,7 @@ import { Form, Input, Button, Radio, Icon, Spin } from "antd"; import { Link } from "react-router-dom"; import "./index.css"; import { turnbar , returnbar } from 'educoder'; +import { Base64 } from 'js-base64'; import axios from "axios"; const TextArea = Input.TextArea; @@ -63,7 +64,7 @@ class UserSubmitComponent extends Component { filepath: filename ? filename : path, branch: returnbar(branch), new_branch: submitType === "1" ? values.branchname : undefined, - content, + content:Base64.encode(content), message: values.desc, }) .then((result) => {