Use getId() instead of mId in getEditCount(), so it works with unloaded user objects
authorAndrew Garrett <werdna@users.mediawiki.org>
Thu, 26 Feb 2009 11:33:23 +0000 (11:33 +0000)
committerAndrew Garrett <werdna@users.mediawiki.org>
Thu, 26 Feb 2009 11:33:23 +0000 (11:33 +0000)
includes/User.php

index cc57c2b..4289b2a 100644 (file)
@@ -2020,7 +2020,7 @@ class User {
         * @return \int User'e edit count
         */
        function getEditCount() {
-               if ($this->mId) {
+               if ($this->getId()) {
                        if ( !isset( $this->mEditCount ) ) {
                                /* Populate the count, if it has not been populated yet */
                                $this->mEditCount = User::edits($this->mId);