dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add a bunch of @since tags to Linker
[lhc/web/wiklou.git]
/
includes
/
WatchedItem.php
diff --git
a/includes/WatchedItem.php
b/includes/WatchedItem.php
index
0495536
..
db6ce87
100644
(file)
--- a/
includes/WatchedItem.php
+++ b/
includes/WatchedItem.php
@@
-18,6
+18,7
@@
* @file
* @ingroup Watchlist
*/
* @file
* @ingroup Watchlist
*/
+use MediaWiki\Linker\LinkTarget;
/**
* Representation of a pair of user and title for watchlist entries.
/**
* Representation of a pair of user and title for watchlist entries.
@@
-140,11
+141,7
@@
class WatchedItem {
*/
public function getTitle() {
if ( !$this->title ) {
*/
public function getTitle() {
if ( !$this->title ) {
- if ( $this->linkTarget instanceof Title ) {
- $this->title = $this->linkTarget;
- } else {
- $this->title = Title::newFromLinkTarget( $this->linkTarget );
- }
+ $this->title = Title::newFromLinkTarget( $this->linkTarget );
}
return $this->title;
}
}
return $this->title;
}