Commit graph

59 commits

Author SHA1 Message Date
CosmicAlpha c2b3cbc6b6
Revert "Improve the performance of rev_page subqueries by using page_id. (#229)" (#230)
This reverts commit f66d48387d.
2023-04-24 12:07:20 -06:00
TehKittyCat 7966936c87
Don't return the viewer's IP address as %USER% if rev_actor is 0. (#228)
User->getName() falls back to the current user's IP address if there is no user name.

Co-authored-by: TehKittyCat <tehkittycat@weirdgloop.org>
2023-04-23 22:51:17 -06:00
TehKittyCat f66d48387d
Improve the performance of rev_page subqueries by using page_id. (#229)
Under MySQL 8 this saved 200 ms off the first run and lets subsequent runs be almost instantaneous.

Co-authored-by: TehKittyCat <tehkittycat@weirdgloop.org>
2023-04-23 22:17:58 -06:00
Marcin Kostrzewski 43864ad019
Fix usedby query returning all templates (#224)
Co-authored-by: Martyna Nowicka <37370506+maaartyyynaa@users.noreply.github.com>
2023-03-16 14:49:35 -06:00
CosmicAlpha 7cf983cb03
Only check for buffer overflow (#223)
The other regex validation seems unnecessary.
2023-03-12 13:18:38 -06:00
CosmicAlpha d4f2f71384
Use ExtensionRegistry::getAllThings() to get version (#220) 2023-02-27 13:02:41 -07:00
CosmicAlpha 757a74b755
phan: enable SecurityCheck-ReDoS (#217) 2023-01-14 11:13:06 -07:00
CosmicAlpha 693336b9fd
Add support for PHP 8.0 and PHP 8.1 (#216) 2023-01-13 14:12:14 -07:00
CosmicAlpha d7336b1a67
Fix for links migration: add JOIN on linktarget for notuses (#213)
Also adds a PHPUnit tests for the notuses parameter.
2023-01-04 11:22:24 -07:00
CosmicAlpha 8dd8d03d61
Support MediaWiki 1.39 for actor and templatelinks migration (#188)
This adds support for 1.39, and drops support for older versions, since 1.39 is the current LTS release.
2022-12-06 17:10:46 -07:00
CosmicAlpha 6ca7c458be
Properly select il_to for use with imagecontainer, passing title 2022-08-11 14:51:06 -06:00
Robert Vogel 64cf6c5976
Fix profiling context calculation (#174)
`ParserFactory::getParser` will create a completely new `Parser` instance.
Based on the context, this instance may have not set a `Title` object.
Thus accessing `Parser::getTitle` without checking for the return value
may break the code.

Issue: https://github.com/Universal-Omega/DynamicPageList3/issues/170

Co-authored-by: rvogel <vogel@hallowelt.biz>
2022-06-24 10:24:49 -06:00
Universal Omega da27636f6b
add additional isset check for mTemplatePath (#167) 2022-04-15 14:08:27 -06:00
Universal Omega c4bff23bf6
Use database update maintenance script for creating VIEW (#165) 2022-04-14 11:50:27 -06:00
Universal Omega 7c2bc69296
phpcs: enable MediaWiki.Commenting.FunctionComment (#149) 2022-03-22 13:59:52 -06:00
Universal Omega be6395a07a
Remove unused LST::noop() function (#148) 2022-03-22 10:37:11 -06:00
Universal Omega 4890c27b7f
Fix %TOTALPAGES% usage (#145) 2022-03-21 15:37:02 -06:00
Universal Omega 02fe40ec52
Fix firstrevisionsince and lastrevisionbefore parameters (#143) 2022-03-20 17:50:19 -06:00
Universal Omega 181a32255e
Only set sqlQuery if used for debug (#142) 2022-03-20 17:14:44 -06:00
Universal Omega d5b353968e
Fix openreferences=missing count (#140) 2022-03-20 16:42:03 -06:00
Universal Omega bc1377bb00
Use ExtensionRegistry for checking HitCounters (#137) 2022-03-20 11:15:43 -06:00
Universal Omega af9d8a4f5e
phpcs: enable SpaceBeforeSingleLineComment.NewLineComment (#138) 2022-03-20 11:11:35 -06:00
Universal Omega edb0836569
Fix allowUnlimitedResults (#131) 2022-03-19 20:52:03 -06:00
Universal Omega c47acf14c6
phpcs: enable PEAR.Functions.ValidDefaultValue.NotAtEnd (#128) 2022-03-17 13:02:52 -06:00
Universal Omega 683294d0ab
Fix minoredits parameter (#127) 2022-03-17 09:38:47 -06:00
Universal Omega 60ec70c079
Properly implement titlemaxlength and includemaxlength (#123) 2022-03-16 17:23:58 -06:00
Universal Omega 5bd1244b34
Remove unused parameters from editTemplateCall (#125) 2022-03-16 16:37:16 -06:00
Universal Omega cb70bf0a8b
Remove some unused code (#124) 2022-03-16 16:10:03 -06:00
Universal Omega 4e5a019adb
Remove unused removeSectionMarkers function (#121) 2022-03-15 14:37:01 -06:00
Universal Omega 1cfaefb084
Fix query error due to not adding quotes to '%' (#119) 2022-03-15 11:11:41 -06:00
Universal Omega 4b41db98f6
Use StringUtils::isValidPCRERegex (#117) 2022-03-14 10:44:46 -06:00
Universal Omega af983cf2df
Re-namespace and use AutoloadNamespaces (#113) 2022-03-13 13:57:34 -06:00
Universal Omega 90c3c0ee6c
Improve query performance and add caching support (#107) 2022-03-13 12:28:30 -06:00
Universal Omega 2ea2503a43
Use Extension:DynamicPageList3 in logger (#111) 2022-03-12 16:12:52 -07:00
Universal Omega cd764c2a1d
Replace usages of globals (#106) 2022-03-09 13:17:24 -07:00
Jack Phoenix c37cda41d9
Use the existing Services object (#105)
It was already defined above, on line 198.

Also compacted the multi-line chained method calls into one line since its length does not exceed 120 characters.
2022-03-08 10:28:46 -07:00
Universal Omega a0a2b862bc
Fix usage of scroll and order in the same query (#88) 2022-02-06 16:27:50 -07:00
Universal Omega ce64f763a3
Add support for openreferences=missing (#87) 2022-02-05 12:33:07 -07:00
Robert Vogel 1024e445ff
Fix second param to preg_match (#78)
Co-authored-by: rvogel <vogel@hallowelt.biz>
2022-01-28 10:07:27 -07:00
Robert Vogel f20ad2e16f
Restore MediaWiki 1.35 compatibility (#79)
Co-authored-by: rvogel <vogel@hallowelt.biz>
2022-01-28 10:06:58 -07:00
Jack Phoenix 20f11dc6b7
Fix up a few minor things which were annoying me (#72)
* Use single quotes instead of double where appropriate, as per MediaWiki's usual coding conventions
* Correctly capitalize `getDBkey` method as such
* Add some spacing etc.
* Capitalize SQL keywords in the exception messages that are thrown
* Fix up indentation and remove one unnecessary variable in function _addcontribution
2021-12-16 18:23:18 -07:00
Universal Omega 78c5ead32c
Fix getSubcategories (#71) 2021-12-16 15:18:01 -07:00
Universal Omega cf3e0566ef
Fix allowUnlimitedResults + fix tests on 1.38.0+ (#70) 2021-12-15 16:23:13 -07:00
Universal Omega 9afe84380a
Cleanup (#64) 2021-12-15 13:22:38 -07:00
Universal Omega 2324ce206a
Revert helper classes (#63) 2021-10-06 12:44:11 -06:00
Universal Omega 8f996a6b25
add phan-var (#61) 2021-10-02 15:55:24 -06:00
Universal Omega 2fe609148c
Fix fatal "Class 'DynamicPageListHooks' not found" 2021-10-02 15:00:01 -06:00
Universal Omega 2c04dafb37
Major cleanup (#57) 2021-10-01 16:52:30 -06:00
Universal Omega 8c9ee66836
Fix setting query limit (#53) 2021-09-24 20:56:23 -06:00
Universal Omega c5a8702106
Fix "Trying to access array offset on value of type null" (#54) 2021-09-15 20:03:00 -06:00