瀏覽代碼

:fire: hiding logs | cleaning up a bit

tags/0.9.0
J 4 年之前
父節點
當前提交
1d1622ca88
共有 1 個檔案被更改,包括 5 行新增5 行删除
  1. 5
    5
      vue-theme/src/pages/list.vue

+ 5
- 5
vue-theme/src/pages/list.vue 查看文件

79
             this.$store.commit(`${uppercaseType}_LOADED`)
79
             this.$store.commit(`${uppercaseType}_LOADED`)
80
         },
80
         },
81
         async loadMorePosts() {
81
         async loadMorePosts() {
82
-            console.log('trying to load for: ', this.$route)
82
+            // console.log('trying to load for: ', this.$route)
83
             const type = typeFromRoute(this.$route)
83
             const type = typeFromRoute(this.$route)
84
-            if(!type) return console.warn(`type: ${type} not found...`)
84
+            if(!type) return console.error(`type: ${type} not found...`)
85
             if(!this.keepFetching) return console.warn('nothing left to fetch...')
85
             if(!this.keepFetching) return console.warn('nothing left to fetch...')
86
 
86
 
87
             console.warn(`loading more ${type} posts...`)
87
             console.warn(`loading more ${type} posts...`)
121
 
121
 
122
             // Stop trying to load more posts
122
             // Stop trying to load more posts
123
             if(res && !res.length) {
123
             if(res && !res.length) {
124
-                console.warn('nothing left to get...')
124
+                console.warn('did not receive response...', res, this.type)
125
                 this.keepFetching = false
125
                 this.keepFetching = false
126
             }
126
             }
127
             this.loadingFetched = false
127
             this.loadingFetched = false
148
             if(!this.type) return console.error('cannot setup intersection handler for undefined type')
148
             if(!this.type) return console.error('cannot setup intersection handler for undefined type')
149
             if(this.type == 'episode') return console.warn('intersection handler not setup for episode')
149
             if(this.type == 'episode') return console.warn('intersection handler not setup for episode')
150
 
150
 
151
-            console.warn('setting up intersection handler for:', this.type)
151
+            // console.warn('setting up intersection handler for:', this.type)
152
             const footerEl = document.querySelector(INTERSECT_SELECTION)
152
             const footerEl = document.querySelector(INTERSECT_SELECTION)
153
             if(!footerEl) return
153
             if(!footerEl) return
154
 
154
 
189
             console.log('new:', newType)
189
             console.log('new:', newType)
190
             
190
             
191
             if(!postTypes.includes(newType)) return console.warn('type not found...')
191
             if(!postTypes.includes(newType)) return console.warn('type not found...')
192
-            this.setIntersectionLoader()
193
             this.clearAndInitPostList()
192
             this.clearAndInitPostList()
193
+            this.setIntersectionLoader()
194
         },
194
         },
195
     },
195
     },
196
     mounted() {
196
     mounted() {

Loading…
取消
儲存