1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-06 09:21:54 +00:00

cloud-edit fix

This commit is contained in:
Michael An
2019-04-19 14:44:24 +08:00
parent 7e541a7bba
commit c9c07dce85

View File

@@ -502,7 +502,8 @@ class MarkdownEditor extends React.Component {
seafileAPI.getFileContent(downLoadUrl).then((res) => {
const contentLength = res.data.length;
let isBlankFile = (contentLength === 0 || contentLength === 1);
let hasPermission = (this.state.fileInfo.permission === 'rw');
let permission = this.state.fileInfo.permission;
let hasPermission = (permission === 'rw' || permission === 'cloud-edit');
let value = deserialize(res.data);
this.setState({
markdownContent: res.data,