mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiEditor
synced 2024-11-24 00:06:49 +00:00
Default user.editCount to 0 in the Edit schema
Otherwise it will fail to validate for anonymous users (getEditCount returns null) as it is a required field Change-Id: I3d438cfde172b2598955773c4c22fc2d4a502f16
This commit is contained in:
parent
f061205405
commit
1096e18a55
|
@ -169,7 +169,7 @@ class WikiEditorHooks {
|
||||||
'page.ns' => $title->getNamespace(),
|
'page.ns' => $title->getNamespace(),
|
||||||
'page.revid' => $page->getRevision() && $page->getRevision()->getId(),
|
'page.revid' => $page->getRevision() && $page->getRevision()->getId(),
|
||||||
'user.id' => $user->getId(),
|
'user.id' => $user->getId(),
|
||||||
'user.editCount' => $user->getEditCount(),
|
'user.editCount' => $user->getEditCount() ?: 0,
|
||||||
'mediawiki.version' => $wgVersion
|
'mediawiki.version' => $wgVersion
|
||||||
) + $data;
|
) + $data;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue