Reviewed: https://reviews.mahara.org/c/mahara/+/13620 Committed: https://git.mahara.org/mahara/mahara/commit/c37d33e817ec9fb0130b155d4ea82f3a5d0ead24 Submitter: "Robert Lyon <[email protected]>" Branch: main
commit c37d33e817ec9fb0130b155d4ea82f3a5d0ead24 Author: Robert Lyon <[email protected]> Date: Mon Jan 16 13:44:48 2023 +1300 Bug 2002924: Making sure block count/limit fields have correct rules They need to be an integer and be between 1 to a sensible higher number, usually 100 Change-Id: I104ad04f7a4b896986d12cd82ec7a60a90c19a41 Signed-off-by: Robert Lyon <[email protected]> -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: mahara-contributors https://bugs.launchpad.net/bugs/2002924 Title: Problem with divide by zero when setting pagination limit Status in Mahara: Fix Committed Bug description: For certain blocks there is the ability to set the 'count' (pagination limit) and if one sets it to a non integer value it causes the error: [DivisionByZeroError]: Modulo by zero We need to set a rule for the field so that it can only be an integer, eg 'rules' => array('integer' => true, 'minvalue' => 1, 'maxvalue' => 100), To test: 1) Create a plan 2) create some tasks 3) Edit a page and add plan block to page view page - all is fine 4) Edit the plan block and set 'count' to 'none' On save - things hang On page reload - see error Can't edit page to fix problem so will mark this bug as high To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/2002924/+subscriptions _______________________________________________ Mailing list: https://launchpad.net/~mahara-contributors Post to : [email protected] Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp

