mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/PageImages
synced 2024-11-15 12:00:40 +00:00
Remove bogus @doc… elements from default $wgPageImagesScores setting
Such @doc… keys are not allowed at this level. They make it to the code and cause confusion there. I added a test case for an edge case where this really causes wrong results. Bug: T212013 Change-Id: Ib391e5639ef5a34f9ee44f8c19b99e1dd19207bc
This commit is contained in:
parent
b058df99b8
commit
baabc300ba
|
@ -38,6 +38,7 @@
|
|||
},
|
||||
"config": {
|
||||
"PageImagesScores": {
|
||||
"@doc": "Images <120px are usually from maintenace or stub templates; >600px are panoramas, less suitable.",
|
||||
"value": {
|
||||
"position": [
|
||||
8,
|
||||
|
@ -46,10 +47,8 @@
|
|||
3
|
||||
],
|
||||
"width": {
|
||||
"@doc119": "Very small images are usually from maintenace or stub templates",
|
||||
"119": -100,
|
||||
"400": 10,
|
||||
"@doc600@": "Larger images are panoramas, less suitable",
|
||||
"600": 5,
|
||||
"601": 0
|
||||
},
|
||||
|
|
|
@ -322,6 +322,8 @@ class LinksUpdateHookHandlerTest extends MediaWikiTestCase {
|
|||
[ 'ratio', 30, 0 ],
|
||||
[ 'ratio', 31, -100 ],
|
||||
[ 'ratio', 40, -100 ],
|
||||
|
||||
'T212013' => [ 'width', 0, -100 ],
|
||||
];
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue