Remove debug console logs
This commit is contained in:
parent
6613de5af9
commit
60f2635e21
|
@ -122,7 +122,6 @@ const memoryCache = new InMemoryCache({
|
|||
media: {
|
||||
keyArgs: ['onlyFavorites'],
|
||||
merge(existing = [], incoming) {
|
||||
console.log('merge media', existing, incoming)
|
||||
return [...existing, ...incoming]
|
||||
},
|
||||
},
|
||||
|
|
|
@ -19,17 +19,14 @@ const useScrollPagination = ({ loading, fetchMore, data, getItems }) => {
|
|||
|
||||
// configure new observer
|
||||
observer.current = new IntersectionObserver(entities => {
|
||||
console.log('Observing', entities)
|
||||
if (entities.find(x => x.isIntersecting == false)) {
|
||||
let itemCount = getItems(data).length
|
||||
console.log('load more', itemCount)
|
||||
fetchMore({
|
||||
variables: {
|
||||
offset: itemCount,
|
||||
},
|
||||
}).then(result => {
|
||||
const newItemCount = getItems(result.data).length
|
||||
console.log('then', result, itemCount, newItemCount)
|
||||
if (newItemCount == 0) {
|
||||
setFinished(true)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue