Commit graph

4065 commits

Author SHA1 Message Date
Translation updater bot 49285be063 Localisation updates from https://translatewiki.net.
Change-Id: I223a49833927444b4153b25bb521060fefc7a5bb
2018-07-31 22:32:50 +02:00
jenkins-bot d6dd82d782 Merge "Get document data using updated interface" 2018-07-29 00:32:45 +00:00
Thalia 2c77a9d66a Get document data using updated interface
Depends-On: Iea426be573f07c976b0c142357d5ed83e51db013
Depends-On: I36dad61ed614f007b16d7e9f47fcbfd02347f239
Change-Id: I9d9615f69d40822a72f31f0d86d7997dd0812523
2018-07-29 00:07:28 +00:00
Translation updater bot 6485e4ec2c Localisation updates from https://translatewiki.net.
Change-Id: Ifbb38f66c68561cb2423717199e731691c298a46
2018-07-28 22:29:33 +02:00
Translation updater bot 0be3b3f652 Localisation updates from https://translatewiki.net.
Change-Id: I8145d76cc0c4bc5beeb9bb9442b8920b71f8a972
2018-07-27 22:17:34 +02:00
libraryupgrader 19eb07b84d build: Updating mediawiki/mediawiki-codesniffer to 21.0.0
The following sniffs are failing and were disabled:
* MediaWiki.Commenting.FunctionAnnotations.UnrecognizedAnnotation

Change-Id: I97d67cdecbc4849a5d73a53852a9b8b4b6139d1c
2018-07-27 03:34:41 +00:00
jenkins-bot 10bb5b6157 Merge "Deal with <references/> inside a <ref> in automatic references list" 2018-07-25 16:23:11 +00:00
Timo Tijhof e86ffeba3a Deal with <references/> inside a <ref> in automatic references list
The Cite extension already had a recursion guard around the parsing of
`<references/>`, to prevent another `<ref>` containing `<references/>`
from producing a weirdly nested references list.

When an explicit `<references/>` tag is not included in the page, or
`<ref>` tags exist after the last explicit `<references/>`, the extension
automatically adds a reference list at the end of the page, to make the
references still displayed.

This automatic references list creation was bypassing the recursion
guard, causing the weirdly nested output *and* a PHP Notice from
`mRefs[$group]` becoming undefined. This commit sets the recursion guard
state during that automatic references list creation to prevent this.

Bug: T182929
Change-Id: I87737dcf39a4fc15e119a1090a9c34d6b9633c21
2018-07-25 15:39:20 +00:00
Translation updater bot 2f7e050056 Localisation updates from https://translatewiki.net.
Change-Id: I32191f9f09e790d44138ab44840642e6f86aa558
2018-07-24 22:09:40 +02:00
Translation updater bot 580a008af7 Localisation updates from https://translatewiki.net.
Change-Id: I5600138f4129aa90d751119b729f0bd358d9fb90
2018-07-23 22:31:02 +02:00
Translation updater bot eebab2324c Localisation updates from https://translatewiki.net.
Change-Id: Iad2da337807804cfc72b9e2409dfe9b1f7098092
2018-07-22 22:08:40 +02:00
Translation updater bot 8b8d2ef640 Localisation updates from https://translatewiki.net.
Change-Id: I6c49d27a991b58b220463c583793c8158abb85c7
2018-07-21 22:11:37 +02:00
Translation updater bot d07660a410 Localisation updates from https://translatewiki.net.
Change-Id: Ic23ea75fe75a3e64a113a7fd1007865d92ef77d6
2018-07-19 22:30:23 +02:00
Translation updater bot 1851e261ea Localisation updates from https://translatewiki.net.
Change-Id: I46dc02571083f2abb636635ba019a8328920295f
2018-07-18 22:12:25 +02:00
Translation updater bot e48b325bc4 Localisation updates from https://translatewiki.net.
Change-Id: I08521fe1f0b95434f0114fcabdb40438818aafc6
2018-07-16 22:19:50 +02:00
Translation updater bot d45b6e8056 Localisation updates from https://translatewiki.net.
Change-Id: Ice8eb50fee9e375b0359516efc944e532c549974
2018-07-14 22:20:22 +02:00
Translation updater bot 046297f360 Localisation updates from https://translatewiki.net.
Change-Id: I8a99726d84ae5de1b6f1df83d388039032d3889d
2018-07-12 22:38:29 +02:00
Translation updater bot e4902524b2 Localisation updates from https://translatewiki.net.
Change-Id: Ia0cc70db00cffa075aeec1d8e0a686c7110af1b5
2018-07-11 22:39:30 +02:00
Translation updater bot c1b77b092e Localisation updates from https://translatewiki.net.
Change-Id: I3f00282a3860cee11e976aa4171ff3562fbfe7db
2018-07-07 22:52:28 +02:00
Translation updater bot bd02bf9557 Localisation updates from https://translatewiki.net.
Change-Id: I4d7c0a80e98b2bf5a37632035c695fb6d8eb65b5
2018-07-05 22:43:39 +02:00
Translation updater bot 65ebb13131 Localisation updates from https://translatewiki.net.
Change-Id: If0c256f33f98baf86c296c35e2a3d22aeb76b809
2018-07-02 22:10:23 +02:00
Translation updater bot a59f8a085d Localisation updates from https://translatewiki.net.
Change-Id: I3e04c8cceae727e5470d4ae4fdb2404639f9bfb8
2018-06-30 22:30:17 +02:00
Translation updater bot 270b1b56ba Localisation updates from https://translatewiki.net.
Change-Id: I3cbf13202bc9fa6053325d3c69600fdbc40f1741
2018-06-29 22:25:43 +02:00
Translation updater bot d0073f4060 Localisation updates from https://translatewiki.net.
Change-Id: I1d70595d17590a80d48f20b878a34f57c7e6e49b
2018-06-28 22:20:58 +02:00
Translation updater bot 3ba755bdd2 Localisation updates from https://translatewiki.net.
Change-Id: I01e328cba818b428b7705df1e896f25f50e60c9c
2018-06-27 22:18:23 +02:00
Translation updater bot c58160888f Localisation updates from https://translatewiki.net.
Change-Id: I3164a5fe13f745279010e2888811ab85aadcf9eb
2018-06-25 22:22:03 +02:00
Translation updater bot 6904eae490 Localisation updates from https://translatewiki.net.
Change-Id: Idd9310f79493db305959bb42439abff880e42731
2018-06-24 22:25:28 +02:00
Translation updater bot 859302a150 Localisation updates from https://translatewiki.net.
Change-Id: I53b320ee8919b9b798dfc35fda2344563f39c6de
2018-06-21 22:42:24 +02:00
Ed Sanders 3b53f6906b Use getHtmlMessage for DiffElement
Bug: T195243
Depends-On: Ib4ad16858e4241d33d018830dbcfded63ff703af
Depends-On: Ib5fa39e4f2f529948354b03a141542e23d169fe0
Change-Id: I4b01904d48a9520c8bb1451e0978aaa404ca858c
2018-06-20 15:31:46 +00:00
Translation updater bot 73ca14bb7d Localisation updates from https://translatewiki.net.
Change-Id: I17d832a454d3f64f1bbeeab8df666bd322bc830a
2018-06-15 22:35:36 +02:00
Translation updater bot 0a0dae10d6 Localisation updates from https://translatewiki.net.
Change-Id: Iaae6fc6de3940e7f1e0d79cded597125500a625d
2018-06-14 22:44:29 +02:00
Translation updater bot 72572ba8a0 Localisation updates from https://translatewiki.net.
Change-Id: I65609ee5a741c0356659b48098d602efe1cf5bcc
2018-06-11 22:33:37 +02:00
libraryupgrader 19b7c6dced build: Updating mediawiki/mediawiki-phan-config to 0.3.0
Change-Id: Id67e06150da6ba5b470957b3d6dd1a974847be89
2018-06-08 06:54:15 +00:00
Translation updater bot 3c6aeebccf Localisation updates from https://translatewiki.net.
Change-Id: I2c2e27f177f3091d909a1fcadc9d8e5840510e85
2018-06-03 22:36:06 +02:00
Translation updater bot 63dbdbf482 Localisation updates from https://translatewiki.net.
Change-Id: I0542ffd798b80596c89486f5e401d5b1cc41a7f2
2018-06-02 22:41:16 +02:00
Translation updater bot 85015573ea Localisation updates from https://translatewiki.net.
Change-Id: If23a26a389b0ba77082b4490538092e104af987f
2018-06-01 22:27:22 +02:00
Ed Sanders 6c38c009d7 Add preview mode converter tests
Change-Id: I2e9dc615a82b725d4061b39e6bdc56350e5d3d1d
Depends-On: I3f1a4772cbf67091b5fd52bab610390ebd9b16ef
2018-05-31 16:27:14 +01:00
Translation updater bot c3363cadae Localisation updates from https://translatewiki.net.
Change-Id: I4070d78d1e7e5ef425ac86294be6e81f9d8583d5
2018-05-29 22:24:43 +02:00
Translation updater bot 7ba27bb832 Localisation updates from https://translatewiki.net.
Change-Id: Ibc4dad7b91176083fc8fb721f960eaaee6f593a8
2018-05-28 22:41:56 +02:00
libraryupgrader ccc3bd2b60 build: Updating mediawiki/mediawiki-codesniffer to 20.0.0
Change-Id: Id797b943c9362b9a327d831284c22838d449d8c0
2018-05-26 01:25:02 +00:00
Translation updater bot 18a2b83694 Localisation updates from https://translatewiki.net.
Change-Id: Id04df14cbc15cda40051955fea054f2842a92d87
2018-05-25 22:14:06 +02:00
Translation updater bot fda8af39b3 Localisation updates from https://translatewiki.net.
Change-Id: Ib69d038dd60ede84108f48c7f1fcacc8a3f8b160
2018-05-24 22:24:44 +02:00
Translation updater bot e6506cdd08 Localisation updates from https://translatewiki.net.
Change-Id: I9f3f34ac163664fcbffe7b1d20d58813bd9c25f4
2018-05-23 22:20:08 +02:00
Translation updater bot 5b5824dabe Localisation updates from https://translatewiki.net.
Change-Id: I35ab3e7ab5ee261eb361da2cd0d3fe1ffaa3a196
2018-05-22 22:20:38 +02:00
Translation updater bot 3640f87085 Localisation updates from https://translatewiki.net.
Change-Id: I9056184ec924f3fa96031ba318041de48470fc3a
2018-05-20 22:44:17 +02:00
Umherirrender 2e4222bd04 Remove reference to archived InlineEditor
Change-Id: Ie549357942a321962e5886c767d36975074f6cb6
2018-05-17 19:24:39 +02:00
Thiemo Kreuz 0fe9dbb366 Don't expect objects by reference in hook handlers
The motivation for this patch is to make the code less complex, better
readable, and less brittle.

Example:

public function onExampleHook( Parser &$parser, array &$result ) {
    /* This is the hook handler */
}

In this example the $result array is meant to be manipulated by the
hook handler. Changes should become visible to the caller. Since PHP
passes arrays by value, the & is needed to make this possible.

But the & is misplaced in pretty much all cases where the parameter is
an object. The only reason we still see these & in many hook handlers
is historical: PHP 4 passed objects by value, which potentially caused
expensive cloning. This was prevented with the &.

Since PHP 5 objects are passed by reference. However, this did not
made the & entirely meaningless. Keeping the & means callees are
allowed to replace passed objects with new ones. The & makes it look
like a function might intentionally replace a passed object, which is
unintended and actually scary in cases like the Parser. Luckily all
Hooks::run I have seen so far ignore unintended out-values. So even if
a hook handler tries to do something bad like replacing the Parser
with a different one, this would not have an effect.

Removing the & does not remove the possibility to manipulate the
object. Changes done to public properties are still visible to the
caller.

Unfortunately these & cannot be removed from the callers as long as
there is a single callee expecting a reference. This patch reduces the
number of such problematic callees.

Change-Id: Ib3a9da257b50326d569ab1973b523c952963c16b
2018-05-17 17:09:55 +00:00
Translation updater bot 9c2789ca6e Localisation updates from https://translatewiki.net.
Change-Id: Iba93fe20dc568ccf33dff04bcc5e3f6fbef738e7
2018-05-16 23:07:37 +02:00
Translation updater bot ddcd9e644a Localisation updates from https://translatewiki.net.
Change-Id: I6c0ddba62a4ec75192123b9c9a685ce21be1632b
2018-05-15 22:24:26 +02:00
Thiemo Kreuz 8a42f61697 Remove all default "return true" from all hook handlers
This is the default for many years now. Returning true does nothing. It's
identical to returning nothing (null). The only meaningful value a hook
handler can return is false, and even this is meaningful only for very
few hooks.

TL;DR: A "return true" in a hook handler is always meaningless, dead code.

I'm interested in this because we (WMDE) might start working on this
extension soon and I want the code to be small and easy to maintain.

Change-Id: If4f32a55cdc38a3cc8af286d1cca7c0089bbfc43
2018-05-15 10:43:23 +02:00