Просмотр исходного кода

rename editablePages to isEditable

kaori 5 лет назад
Родитель
Сommit
e3b7bbf877
2 измененных файлов с 3 добавлено и 3 удалено
  1. 2 2
      src/client/js/legacy/crowi.js
  2. 1 1
      src/client/js/services/PageContainer.js

+ 2 - 2
src/client/js/legacy/crowi.js

@@ -201,13 +201,13 @@ $(() => {
 
 window.addEventListener('load', (e) => {
   const { appContainer, pageContainer } = window;
-  const editablePages = pageContainer;
+  const isEditable = pageContainer;
 
   // hash on page
   if (window.location.hash) {
     const navigationContainer = appContainer.getContainer('NavigationContainer');
 
-    if (window.location.hash === '#edit' && editablePages) {
+    if (window.location.hash === '#edit' && isEditable) {
       navigationContainer.setEditorMode('edit');
 
       // focus

+ 1 - 1
src/client/js/services/PageContainer.js

@@ -134,7 +134,7 @@ export default class PageContainer extends Container {
   }
 
 
-  get editablePages() {
+  get isEditable() {
     const { appContainer } = window;
     const { currentUser } = appContainer;
     const {