Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Calviño Sánchez <danxuliu@gmail.com>2021-02-09 06:47:22 +0300
committerDaniel Calviño Sánchez <danxuliu@gmail.com>2021-02-09 06:47:22 +0300
commitcf6db57bb13ec65978233ca58effa8e34e9f243e (patch)
tree9ba71a37224fea5dae72f789ba8b17211049b3a8
parentd56d1a15d2944cb27e36ee6af947fe18de06da5d (diff)
Prevent current page in grid to become negative
If the number of pages was -1 (which happens if there are no remote videos and thus "slots" becomes -1) the current page became -2. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
-rw-r--r--src/components/CallView/Grid/Grid.vue2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/components/CallView/Grid/Grid.vue b/src/components/CallView/Grid/Grid.vue
index b3eb8315d..4a62a524f 100644
--- a/src/components/CallView/Grid/Grid.vue
+++ b/src/components/CallView/Grid/Grid.vue
@@ -483,7 +483,7 @@ export default {
numberOfPages() {
if (this.currentPage >= this.numberOfPages) {
- this.currentPage = this.numberOfPages - 1
+ this.currentPage = Math.max(0, this.numberOfPages - 1)
}
},
},