(bug 41171) Refactor User::edits() and User::incEditCount()
User::edits() lets you fetch a cached number of edits from a slave database.
in case the field is not yet filed, we initialize if by hitting the `revision`
table and saving the result in user_editcount.
User::incEditCount() updates the edit countr and also does a lazy
initialization, if needed.
As both methods use the same $dbw->update() statement for this, I've
created a new, protected initEditCount() function which can take care of that.
Change-Id: If111270a84d4278bc4ea14d32ae602069f7c276f