Kaynağa Gözat

modify PageStatusAlert behavior

Yuki Takei 7 yıl önce
ebeveyn
işleme
35262697e2
1 değiştirilmiş dosya ile 2 ekleme ve 4 silme
  1. 2 4
      resource/js/components/PageStatusAlert.jsx

+ 2 - 4
resource/js/components/PageStatusAlert.jsx

@@ -113,10 +113,8 @@ class PageStatusAlert extends React.Component {
     const isRevisionOutdated = this.state.initialRevisionId !== this.state.revisionId;
     const isHackmdDocumentOutdated = this.state.revisionId !== this.state.revisionIdHackmdSynced;
 
-    if (isHackmdDocumentOutdated) {
-      if (isRevisionOutdated) {
-        content = this.renderUpdatedAlert();
-      }
+    if (isHackmdDocumentOutdated && isRevisionOutdated) {
+      content = this.renderUpdatedAlert();
     }
     else {
       if (this.state.isDraftUpdatingInRealtime) {