Reviewed: https://reviews.mahara.org/10929 Committed: https://git.mahara.org/mahara/mahara/commit/01eed8e415421e4fd4c8b1976a1d1669287d3305 Submitter: Cecilia Vela Gurovic ([email protected]) Branch: 20.04_STABLE
commit 01eed8e415421e4fd4c8b1976a1d1669287d3305 Author: Rebecca Blundell <[email protected]> Date: Mon Jan 13 16:19:13 2020 +1300 Bug 1839411: Update Mahara to work with PHP7.3/7.4 Fixed strpos error picked up by 7.3 I haven't found any other 7.3 issues and none have been caught by behat For 7.4: -Fixed implode param order (glue, parts) Note that Mink has a reversed implode not fixed upstream: external/vendor/behat/mink/src/Selector/Xpath/Escaper.php:50 I have added a function to copy the correct code over in the interim I also pushed a change to an HTMLPurifier file as it is not fixed upstream -Changed a variable read by fread to allow for false return type -Calling a non-array as an array now causes an error, meaning we need to confirm an array value before attempting to use a variable. An obvious case is in multi-record db calls the return value is either an array of results or false. E.g. $array = db_call();//returns false as no results //do sth with result $var = $array[0]//error, trying to access type false as array //instead we need to check the value before accessing: $var = !empty($array[0]) ? $array[0] : false //or some equivalent check of the db_call's return Because of this change, I have attempted to check all the multi-db calls for possible false results and include a check for that if there wasn't already one. -In conjunction with the previous work, I noticed that trying to use foreach on a non-iterable result causes an error and that array functions (i.e. array_keys()) called on a non-array also cause an error. Where I found them I added checks as well. -A change in PHP7.2 was that items counted with count() must implement Countable. (i.e, int/bool is not OK). I fixed the ones I found. -I used the regex \{\$?\d?[^\s]\} to search for array access using {} instead of [] and changed those. (Note: the regex pulls in a lot more) CSStidy has a lot of these that aren't fixed, but those are covered by the CSStidy upgrade (Bug 1840099) Change-Id: I64a8feb821433ecd99463762a9999449c50ee32e (cherry picked from commit 4263848b4e4cc87a57d8719123b7a363bcbebf45) -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1840099 Title: Library upgrade: CSS Tidy to 1.7.1 Status in Mahara: Fix Committed Status in Mahara 20.04 series: Fix Committed Bug description: Related to: https://bugs.launchpad.net/mahara/+bug/1827291 Update CSS Tidy to 1.7.0 for support of nested @media and @supports rules https://github.com/Cerdic/CSSTidy To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1840099/+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

