Commit graph

6839 commits

Author SHA1 Message Date
Thiemo Kreuz be3af66876 Simplify code dealing with filter ids in FilterStore
Before the information if a filter was new was stored in 2 places:
In the bool $isNew and in the two variables $filter and $newID.
$newID was especially confusing because it was used for both old and
new ids.

Change-Id: I15bdf36c96c8d86a37f305aab2647f7d57bc2bf1
2022-04-27 19:29:55 +02:00
jenkins-bot b1ea4f2d69 Merge "FilterStore: Use upsert instead of replace" 2022-04-27 11:58:24 +00:00
jenkins-bot fa068d2bb5 Merge "Inline/simplify smaller pieces of JavaScript code" 2022-04-26 16:22:12 +00:00
jenkins-bot 5794ad8302 Merge "Fix capitalization of method calls accross the codebase" 2022-04-26 16:19:57 +00:00
Thiemo Kreuz e73f2076ad Inline/simplify smaller pieces of JavaScript code
The check if $() found an element is not needed. Method calls will
operate happily on an empty result and do nothing, as expected.

Change-Id: I985ac4623d7968f037613174b14348885afed7d1
2022-04-26 17:44:17 +02:00
Thiemo Kreuz a25e2c784a Fix capitalization of method calls accross the codebase
Change-Id: Icbbad4858735c24611daee693c53af479c75d1fb
2022-04-26 17:42:34 +02:00
Amir Sarabadani c1d8037815 FilterStore: Use upsert instead of replace
You should never write to auto_increment value.

Bug: T306692
Change-Id: I363711336658a24a0dedf42643296185dfa4a024
2022-04-26 17:10:03 +02:00
Translation updater bot 1ed871a090 Localisation updates from https://translatewiki.net.
Change-Id: Ia69e1e8eb4d7efd29f0502e099b9d5381d41be7f
2022-04-26 08:53:19 +02:00
Translation updater bot f740d72648 Localisation updates from https://translatewiki.net.
Change-Id: Ibe4d3d85622ffb734cb46a6847d45bf4c3590b87
2022-04-25 08:16:34 +02:00
Umherirrender 89df7dfddb Remove index detection 'rev_page_timestamp'
Rename in 1.37

Change-Id: Ia9a7682f9f9751de3071b0a644d945dbbd3ed824
2022-04-22 19:26:36 +02:00
Translation updater bot 64874756ee Localisation updates from https://translatewiki.net.
Change-Id: Ia9ce1b2ef6f8e4f09afec73b91f787f9b90d15c1
2022-04-21 08:11:43 +02:00
proc 1d1215bafb
Add support for regex string replacements.
Bug: T285468
Change-Id: I25f8ad1b58cc10f4c6f6ef5ebab99fe58ec71b1e
2022-04-20 18:38:24 +01:00
Translation updater bot 6cd4fa477e Localisation updates from https://translatewiki.net.
Change-Id: I86e3d3f0a5e66f18c7e212654c32dfc1bf976318
2022-04-19 10:13:39 +02:00
Translation updater bot c4779ed18a Localisation updates from https://translatewiki.net.
Change-Id: I5bf69465459b23e1c377c94310c4d96aa7c23586
2022-04-18 10:04:58 +02:00
Translation updater bot 81b99aad53 Localisation updates from https://translatewiki.net.
Change-Id: Ia0851a4300f0c8026d7cff3ef644281004205a30
2022-04-15 09:55:12 +02:00
Translation updater bot b7d55268c4 Localisation updates from https://translatewiki.net.
Change-Id: Ieb96bcaa92fb555941f203899482800c8be28ba3
2022-04-14 08:25:26 +02:00
jenkins-bot b94cd470db Merge "Inject dependencies into the authentication provider" 2022-04-12 13:17:53 +00:00
Translation updater bot 2c5657af32 Localisation updates from https://translatewiki.net.
Change-Id: Ia1e1a384359442ff7bd4003900b67993436a27a2
2022-04-12 08:13:21 +02:00
Translation updater bot 8fa07e6321 Localisation updates from https://translatewiki.net.
Change-Id: I97b81bb5b772394966f2898d5a11fbff6447d5b9
2022-04-11 08:13:21 +02:00
Daimona Eaytoy 59eb3b70fb Inject dependencies into the authentication provider
- Define it with the extension.json key, instead of using the
  registration callback
- Inject the services it needs
- Replace direct User instantiation with UserFactory
- Move log subtypes to extension.json as well

Change-Id: I86a761c7fa844b1f417b974798373622a15f6411
2022-04-09 18:44:25 +02:00
Translation updater bot 821b58fe94 Localisation updates from https://translatewiki.net.
Change-Id: I904a70c4673c1b1b83164faec1bfbe5bec151444
2022-04-08 08:26:33 +02:00
Translation updater bot ecc6ee295b Localisation updates from https://translatewiki.net.
Change-Id: I070ca68ab0686bded168183d9a4093fcb64e09ed
2022-04-07 08:08:45 +02:00
jenkins-bot c7903f9a7c Merge "Fix check for null Content in getEditTextForFiltering" 2022-04-06 17:40:31 +00:00
Translation updater bot 932689ca5d Localisation updates from https://translatewiki.net.
Change-Id: I3b8839cbd97d4ef9bd0838bc2c691153b36fa0d0
2022-04-06 08:26:20 +02:00
Translation updater bot 065b4dfa6b Localisation updates from https://translatewiki.net.
Change-Id: Iaebbba4a4c447033033556219c7c401d1d948dfc
2022-04-05 08:24:38 +02:00
jenkins-bot 23981a5900 Merge "Localisation updates from https://translatewiki.net." 2022-04-04 07:37:56 +00:00
Translation updater bot 733992d73a Localisation updates from https://translatewiki.net.
Change-Id: I841cf708e9debec960a12a2915ec60e416cfdca6
2022-04-04 09:33:33 +02:00
Translation updater bot 354cb06634 Localisation updates from https://translatewiki.net.
Change-Id: Ib17bad7bd065e7c27e8725f1d5f12cfa89e8960d
2022-04-04 09:12:57 +02:00
gerritbot 8e55018613 Fix usage of ApiBase::PARAM_* deprecated constants
The ones that are replaced with ParamValidator

Bug: T275455
Change-Id: If1fbef4707eecd7a6bfa5947614fe46d70c62dd6
2022-04-04 00:49:37 +00:00
gerritbot a617a846f0 Replace deprecated ApiBase::PARAM_ with IntegerDef ones
The rest of ApiBase::PARAM_  will be done in separate patches

Bug: T275455
Change-Id: I1c836d2d85e3004e8b6b1a53e11770910acc0616
2022-04-03 22:13:20 +02:00
Matěj Suchánek 58dfab4aeb Fix check for null Content in getEditTextForFiltering
The check was not consistent and the code could still crash
when $oldContent was null. RevisionRecord:getContent only
returns null when audience check fails, but we don't ask
for that.

Change-Id: Id64646a6762167f552e104f623130bedc6b2dd18
2022-04-03 13:06:24 +02:00
Translation updater bot cdc6aba3f8 Localisation updates from https://translatewiki.net.
Change-Id: I13dad966fee76eee5a426a472d6e5e375f32ef7d
2022-04-01 08:25:28 +02:00
Translation updater bot f2eec6f2db Localisation updates from https://translatewiki.net.
Change-Id: I88014530044224d2f7f1b45a7dd9ddb04f648bbb
2022-03-31 08:35:12 +02:00
jenkins-bot 59def97891 Merge "Use RestrictionStore instead of deprecated method" 2022-03-30 09:59:35 +00:00
Matěj Suchánek 686d7ea88c Use RestrictionStore instead of deprecated method
Also restructure the unit test a bit.

Change-Id: If5ce26f1bc4efdb29653aed3fc47335dddc1e44c
2022-03-29 16:11:55 +02:00
Translation updater bot 20b379f198 Localisation updates from https://translatewiki.net.
Change-Id: I2fbdcc9253dbd5e70e10e0ed151e8343d6830f16
2022-03-29 08:05:09 +02:00
Translation updater bot 0a9520755c Localisation updates from https://translatewiki.net.
Change-Id: I69c5d14a4133a8316011098ba04320713a43b85a
2022-03-28 08:19:29 +02:00
jenkins-bot 50311e750d Merge "Remove SpecialAbuseLog::isHidden" 2022-03-27 18:27:05 +00:00
Func 24f5ca6e2d Use setTitle() instead of setAction() where posible
The getLocalURL() method can return url with query string when
wgArticlePath is configured to do so, and query string of GET form
would be ignored by browsers.
The setAction() method is problematic (T285464 and above) and hard to
warn the wrong usage. I'm going to go through and fix every use case,
and finally deprecate it.

Change-Id: I66b634f0cc996be3d7048d410b46fe77c88f9879
2022-03-27 21:06:38 +08:00
jenkins-bot bd309bb220 Merge "Clean up test files" 2022-03-25 21:28:10 +00:00
Daimona Eaytoy 773d553c8e Remove SpecialAbuseLog::isHidden
This is a breaking change for the API: 'hidden' is now either true or
false, depending on afl_deleted. 'implicit' is no longer a possible
value, the caller should compute it instead if necessary.

Then simplify the remaining usage of isHidden, using a temporary private
method.

Bug: T291718
Change-Id: I97b5195d306c35ddca3f071d9ff4d896f9fd5c8d
2022-03-25 21:22:59 +00:00
Translation updater bot 4055aa0b01 Localisation updates from https://translatewiki.net.
Change-Id: I088cf5cbfc55ae13960b76e14c7dac07887426df
2022-03-25 08:34:18 +01:00
Translation updater bot cbd29a5ef5 Localisation updates from https://translatewiki.net.
Change-Id: I02c108628a0bfa2744daa1f8aa06aa3d4c8ece84
2022-03-24 08:33:30 +01:00
jenkins-bot def507f6d3 Merge "Refactor ConsequencesExecutor to process consequences in more steps" 2022-03-23 09:06:55 +00:00
Translation updater bot 5e7cfb1de7 Localisation updates from https://translatewiki.net.
Change-Id: I907ae7ae8433e9c55d6c9c33e3258b5e5b64a8f8
2022-03-23 08:24:55 +01:00
Translation updater bot 5ea3c5aa5d Localisation updates from https://translatewiki.net.
Change-Id: Id14453cfe95d96b79a7ab87ddf4643fd92fa2ed3
2022-03-22 08:28:27 +01:00
jenkins-bot 84f9e2a6d2 Merge "Replace (error|warning|success)box in test cases of AbuseFilter" 2022-03-21 12:09:29 +00:00
Translation updater bot b973953982 Localisation updates from https://translatewiki.net.
Change-Id: I2bc6d881120e6c187dd6628c207ca8b70a8bffb0
2022-03-21 08:13:53 +01:00
stang f20699935a Replace (error|warning|success)box in test cases of AbuseFilter
Bug: T304243
Change-Id: Iae2b968fc4c84bf360489ec8ff3491afd476c898
2022-03-20 20:16:31 +00:00
Daimona Eaytoy 8ee9a21750 Clean up test files
Convert a few integration tests to unit tests now that it's possible,
split the AbuseFilterSaveTest file into three different classes.

Change-Id: Ia2c0d7ab878b20a89324336a532abdc44f1e6b74
2022-03-20 17:40:49 +00:00