dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
43efaf2
)
mediawiki.Title: Remove unnecessary type check on private function
author
Fomafix
<fomafix@googlemail.com>
Sat, 4 Aug 2018 17:43:06 +0000
(19:43 +0200)
committer
Fomafix
<fomafix@googlemail.com>
Sat, 4 Aug 2018 17:50:59 +0000
(19:50 +0200)
The private function text() is always called with type string.
Change-Id: I5c473215eae4d6da5070478e36156740c1a0a11e
resources/src/mediawiki.Title/Title.js
patch
|
blob
|
history
diff --git
a/resources/src/mediawiki.Title/Title.js
b/resources/src/mediawiki.Title/Title.js
index
c02af98
..
1d0aa67
100644
(file)
--- a/
resources/src/mediawiki.Title/Title.js
+++ b/
resources/src/mediawiki.Title/Title.js
@@
-365,11
+365,7
@@
* @return {string}
*/
text = function ( s ) {
* @return {string}
*/
text = function ( s ) {
- if ( s !== null && s !== undefined ) {
- return s.replace( /_/g, ' ' );
- } else {
- return '';
- }
+ return s.replace( /_/g, ' ' );
},
/**
},
/**