zamis 5 лет назад
Родитель
Сommit
78307ffe17
1 измененных файлов с 5 добавлено и 2 удалено
  1. 5 2
      src/client/js/components/Page/RevisionLoader.jsx

+ 5 - 2
src/client/js/components/Page/RevisionLoader.jsx

@@ -56,8 +56,11 @@ class RevisionLoader extends React.Component {
         this.props.onRevisionLoaded(res.data.revision);
         this.props.onRevisionLoaded(res.data.revision);
       }
       }
     }
     }
-    catch (errors) {
-      errors.forEach((error) => { this.setState({ markdown: error.message }) });
+    catch (error) {
+      console.log(error);
+      // errors.forEach((error) => { this.setState({ markdown: error.message }) });
+      // this.setState({ error });
+      this.setState({ error: error[0].message });
     }
     }
     finally {
     finally {
       this.setState({ isLoaded: true, isLoading: false });
       this.setState({ isLoaded: true, isLoading: false });