aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/main.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs
index 141e353..fc761fb 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -650,7 +650,7 @@ impl Bk<'_> {
fn scroll_up(&mut self, n: usize) {
if self.line > 0 {
self.line = self.line.saturating_sub(n);
- } else {
+ } else if self.chapter > 0 {
self.prev_chapter();
self.line = self.chap().lines.len().saturating_sub(self.rows);
}