| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Bug: T353458
Change-Id: I35864ad9bd48701703c51367d62f8ebde963c52d
|
|
|
|
|
|
|
|
|
| |
isset() should only be used to suppress errors, not for null check.
When the property is always defined, there is no need to use isset.
Found by a new phan plugin (2efea9f989)
https://www.mediawiki.org/wiki/Manual:Coding_conventions/PHP#isset
Change-Id: Ib84b7d71e8308a36409f30ecfd16e9de149e97b3
|
|
|
|
|
|
|
|
|
|
| |
Add doc-typehints to class properties found by the PropertyDocumentation
sniff to improve the documentation.
Once the sniff is enabled it avoids that new code is missing type
declarations. This is focused on documentation and does not change code.
Change-Id: I07ce1f37d1bfb18d6e73dd008a712b3ca60a80e9
|
|
|
|
|
|
|
|
|
|
|
|
| |
AssembleUploadChunks was calculating the SHA1 hash of the same
file 5 times in a row. Calculating SHA1 hashes can be somewhat
expensive for multi-GB files, making the job slow, possibly to
the point of a timeout. This change ensures that the SHA1 value
is kept and reused when applicable so that the job will only
calculate it once.
Bug: T200820
Change-Id: I842814c7a2b7dc6e427e040c8dd4d43e7c7cabb4
|
|
|
|
|
|
|
| |
SpecialPageFactory is already here, but none of the others were yet.
Bug: T166010
Change-Id: I9689bf0a1ab329625e23669b99f019b96295fffd
|
|
|
|
|
|
|
| |
Use the new function in conditions to avoid creating substrings or to
search the whole string
Change-Id: Ibad6b1b447a4f62cceb34359231f88ebb967a90b
|
|
|
|
|
|
|
|
|
| |
Some function already document "False on failure", but does not document
it on the used type
Found by phan strict checks
Change-Id: I12eb8bbc99179833ee3e42c1a7d1dc1443682ca6
|
|
|
|
|
| |
Bug: T254646
Change-Id: I096b2cf738a1395a14f1d47bcbed0c2c686c2581
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A terminating line break has not been required in wfDebug() since 2014,
however no migration was done. Some of these line breaks found their way
into LoggerInterface::debug() calls, where they mess up the formatting
of the debug log.
So, remove terminating line breaks from wfDebug() and
LoggerInterface::debug() calls.
Also:
* Fix the stripping of leading line breaks from the log header emitted
by Setup.php. This feature, accidentally broken in 2014, allows
requests to be distinguished in the log file.
* Avoid using the global variable $self.
* Move the logging of the client IP back to Setup.php. It was moved to
WebRequest in the hopes that it would not always be needed, however
$wgRequest->getIP() is now called unconditionally a few lines up in
Setup.php. This means that it is put in its proper place after the
"start request" message.
* Wrap the log header code in a closure so that variables like $name do
not leak into global scope.
* In Linker.php, remove a few instances of an unnecessary second
parameter to wfDebug().
Change-Id: I96651d3044a95b9d210b51cb8368edc76bebbb9e
|
|
|
|
| |
Change-Id: Idf7cbb6846b05e6eac8dddd4d160d00b9477ee10
|
|
Change-Id: I557bcd8369014bf2ea43c5eb8336562cb6295890
|