summaryrefslogtreecommitdiff
path: root/data/rbot
diff options
context:
space:
mode:
Diffstat (limited to 'data/rbot')
-rw-r--r--data/rbot/plugins/script.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/data/rbot/plugins/script.rb b/data/rbot/plugins/script.rb
index 8234442c..171dabcb 100644
--- a/data/rbot/plugins/script.rb
+++ b/data/rbot/plugins/script.rb
@@ -112,7 +112,7 @@ class ScriptPlugin < Plugin
cmds_per_page = 30
cmds = @commands.keys.sort
- num_pages = cmds.length / cmds_per_page
+ num_pages = cmds.length / cmds_per_page + 1
page = params[:page].to_i
page = [page, 1].max
page = [page, num_pages].min