From 431dac800a3d5fbdaca4a6bf539b5fc167c9ff5a Mon Sep 17 00:00:00 2001 From: Muhammed Mustafa Date: Thu, 28 Sep 2023 04:27:01 +0000 Subject: [PATCH] fix: Fixed issue with pagination --- packages/nc-gui/components/nc/Pagination.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nc-gui/components/nc/Pagination.vue b/packages/nc-gui/components/nc/Pagination.vue index 1d17e4dc1c..56259cad0b 100644 --- a/packages/nc-gui/components/nc/Pagination.vue +++ b/packages/nc-gui/components/nc/Pagination.vue @@ -13,7 +13,7 @@ const current = useVModel(props, 'current', emits) const pageSize = useVModel(props, 'pageSize', emits) -const totalPages = computed(() => Math.ceil(total.value / pageSize.value)) +const totalPages = computed(() => Math.max(Math.ceil(total.value / pageSize.value), 1)) const { isMobileMode } = useGlobal()