Topic on Extension talk:Favorites

Error on Empty Favorites List [MW1.27.1]

2
Jkmartindale (talkcontribs)

I created an empty page with <favorites editlink=true /> when I had an empty favorites list, and it resulted in Error from line 145 of extensions/Favorites/FavParser.php: Call to undefined method FavParser::msg().

Jkmartindale (talkcontribs)
Solution

Edit line 145 of FavParser.php:

138 private function showNormalForm( $output, $user ) {
139 
140 	if ( $this->countFavoritelist($user ) > 0 ) {
141 		$form = $this->buildRemoveList( $user );
142 		$output .=  $form ;
143 		return $output;
144 	} else {
145 		$output = $this->msg('nofavoritelist')->text();
146 		return $output;
147 	}
148 }

to

145 		$output = wfMessage('nofavoritelist')->text();
Reply to "Error on Empty Favorites List [MW1.27.1]"