]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
[Minor] Fixed nil batch_size on default dump on statistics_dump
authorJose Celestino <japc@co.sapo.pt>
Thu, 6 Feb 2025 01:38:52 +0000 (01:38 +0000)
committerJose Celestino <japc@co.sapo.pt>
Thu, 6 Feb 2025 01:38:52 +0000 (01:38 +0000)
lualib/rspamadm/statistics_dump.lua

index 6bc0458501ea060bb9079a2944e123d379a57f85..cbd0bce142a143e55f85da999cfe615a886e7a07 100644 (file)
@@ -42,6 +42,12 @@ parser:option "-c --config"
       :argname("<cfg>")
       :default(rspamd_paths["CONFDIR"] .. "/" .. "rspamd.conf")
 
+parser:option "-b --batch-size"
+    :description "Number of entries to process at once"
+    :argname("<elts>")
+    :convert(tonumber)
+    :default(1000)
+
 -- Extract subcommand
 local dump = parser:command "dump d"
                    :description "Dump bayes statistics"
@@ -54,7 +60,7 @@ dump:mutex(
 dump:flag "-c --compress"
     :description "Compress output"
 dump:option "-b --batch-size"
-    :description "Number of entires to process at once"
+    :description "Number of entries to process at once"
     :argname("<elts>")
     :convert(tonumber)
     :default(1000)
@@ -68,12 +74,12 @@ restore:argument "file"
        :argname "<file>"
        :args "*"
 restore:option "-b --batch-size"
-       :description "Number of entires to process at once"
+       :description "Number of entries to process at once"
        :argname("<elts>")
        :convert(tonumber)
        :default(1000)
 restore:option "-m --mode"
-       :description "Number of entires to process at once"
+       :description "Number of entries to process at once"
        :argname("<append|subtract|replace>")
        :convert {
   ['append'] = 'append',
@@ -541,4 +547,4 @@ return {
   aliases = { 'stat_dump', 'bayes_dump' },
   handler = handler,
   description = parser._description
-}
\ No newline at end of file
+}