mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Cite
synced 2024-11-12 01:01:29 +00:00
a00b8d990d
While working on the patch I4303642 I was worried about the line array_pop( $this->refCallStack ) in the rollback code. Since the patch changed the position of follow elements in the stack, an array_pop() would pop different elements. It turns out this is impossible. Rollbacks are only done for <ref> elements inside a <references> tag, immediatelly after reaching the closing </references>. It's impossible to use follow="…" inside <references>. It will not be added to the stack, and therefore not rolled back. Even if the edge case would be possible, the *old* code that placed follow elements on the *other* side of the stack would have been wrong then. The test cases in this patch try to hit this edge case, and are expected to not be able to do so. Change-Id: I4380bf443db17c6214dbfa2cbda62b46db04258a |
||
---|---|---|
.phan | ||
i18n | ||
modules | ||
src | ||
tests | ||
.eslintrc.json | ||
.gitignore | ||
.gitreview | ||
.phpcs.xml | ||
.stylelintrc.json | ||
AUTHORS.txt | ||
CODE_OF_CONDUCT.md | ||
composer.json | ||
COPYING.txt | ||
extension.json | ||
Gruntfile.js | ||
MIT-LICENSE.txt | ||
package-lock.json | ||
package.json | ||
README.md |
Cite
The Cite extension provides a way for users to create references as footnotes to articles.
See https://www.mediawiki.org/wiki/Extension:Cite for detailed documentation.