| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Found via disabling phan's alias support for a run (and ignoring wgLang's
hard-coded state of being a \Language, alas).
Change-Id: I4753bcd84d72d6de111fc7ffc5841fa417bf7333
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I assume these are all either auto-generated by an IDE or the
language-level type declarations have been added later. In any case
the comments don't add any new information to what the code already
says. This is just extra clutter that makes the code harder to read,
I would argue.
There are many, many more comments like this. In this patch I
intentionally focus on the most trivial 1-line comments.
Change-Id: Ia294bf4ce0d8a77036842fe25884bc175c2b0e7d
|
|
|
|
|
|
|
| |
Changes to the use statements done automatically via script
Addition of missing use statement done manually
Change-Id: I73fb416573f5af600e529d224b5beb5d2e3d27d3
|
|
|
|
|
|
|
| |
Also a few other fixes of PHP class aliases spotted by phan.
Bug: T353458
Change-Id: Ie79d65722c47c24f8f20f1293355cfd3c2e8c2ad
|
|
|
|
|
|
|
|
| |
This skips ones that have been marked but were never in the then
RELEASE-NOTES and later HISTORY file, and so weren't properly
deprecated ever.
Change-Id: I31df2d7e83182b5bf9524237fc4a1862356bfd5a
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Updating name & email addresses for Brooke Vibber.
Re-ran updateCredits.php as well so there are some new entries in
there as well.
There are a couple of files in resources/libs that will have to
be changed upstream to keep tests happy, I will do patches
later. :D
Change-Id: I2f2e75d3fa42e8cf6de19a8fbb615bac28efcd54
|
|
|
|
|
|
|
|
|
|
|
|
| |
Update cases where one of the IConnectionProvider methods is called
immediately.
This doesn't really change anything, but I hope it helps promote
getConnectionProvider() as the common way to do this.
Follow-up to 8604c384f624273f46b653ec252ffaed30e6ff89.
Change-Id: Id0e7d02bab0c570343c2b1f03c70b44ee39db112
|
|
|
|
|
|
|
|
|
| |
Tests are not checked.
There is nothing left as far I can check.
Bug: T353219
Change-Id: I1d58397118c7ab1110b9d7cf400c59c4bff7378c
|
|
|
|
|
|
| |
Also remove redundant doc comments.
Change-Id: I2e4eb3f287b6b715dc392811687fdfb9a611b773
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This function is uber-deprecated, meaning even its replacement is
deprecated, We have already migrated in static functions and more.
In this batch, all calls have been migrated that there is already a call
to MediaWikiServices::getInstance() making the migration easier. Of
course in most cases, they should eventually turn into proper service
injection but this at least makes it clear what services should be
injected.
Also removing "category" group since we are removing all groups except a
handful from mw (see T263127 for more information).
Bug: T330641
Change-Id: I90cd35ee45a37eb6e6bf7a531cc8f75effbd0328
|
|
|
|
|
|
|
| |
We need a pure UserIdentity.
Bug: T347228
Change-Id: Ib52fbc6c797215d7b9b62d99f941d6996bf2d59a
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
I fixed some edge cases in the script that migrates to SQB and it
managed to fix these now.
Bug: T344971
Change-Id: I00cc9a6660d9bd4c64c976121b2121ccd7aae1f0
|
|/
|
|
|
| |
Bug: T166010
Change-Id: I7257302b485588af31384d4f7fc8e30551f161f1
|
|
|
|
|
| |
Bug: T328220
Change-Id: I66be7a6dd752d6b9c254beb65f4eb5ace3c89776
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is moderately messy.
Process was principally:
* xargs rg --files-with-matches '^use Title;' | grep 'php$' | \
xargs -P 1 -n 1 sed -i -z 's/use Title;/use MediaWiki\\Title\\Title;/1'
* rg --files-without-match 'MediaWiki\\Title\\Title;' . | grep 'php$' | \
xargs rg --files-with-matches 'Title\b' | \
xargs -P 1 -n 1 sed -i -z 's/\nuse /\nuse MediaWiki\\Title\\Title;\nuse /1'
* composer fix
Then manual fix-ups for a few files that don't have any use statements.
Bug: T166010
Follows-Up: Ia5d8cb759dc3bc9e9bbe217d0fb109e2f8c4101a
Change-Id: If8fc9d0d95fc1a114021e282a706fc3e7da3524b
|
|
|
|
|
|
|
|
|
|
| |
Not used anywhere else:
https://codesearch.wmcloud.org/search/?q=[%3E:]sha1base36%5Cb&files=%5C.php%24
This allows us to remove the `false` so we can later type the property
with `?string`, if we want.
Change-Id: I4d40ea90f63ba9de1d7558980127691691010325
|
|
|
|
|
|
| |
It has been deprecated since 1.31 and it is unused.
Change-Id: I3c106c6aa3726ec0d36bb5f05af81717425b9af5
|
|
|
|
|
|
|
|
| |
Also, added a parameters to XmlDumpWriter so that they could be
inject via WikiExporter.
Bug: T325475
Change-Id: I84b82506509e2c09dad0691af2df958a5af5b5b0
|
|
|
|
|
|
|
|
|
|
| |
so that extensions (i.e. CheckUser) can implement their own comment
store without having a lot of code duplication
basically the comment store version of I3a6486532f2ef36
Bug: T233004
Change-Id: Ib40f99e00a514d41776ce521baf113e46d37e9cd
|
|
|
|
|
|
| |
New feature from PHP 7.4
Change-Id: Ifa7a9bc7b2ec415ad7ecb23f4c1776f51f58fd6b
|
|
|
|
|
|
| |
Doc-only changes
Change-Id: I5177f582ae7ee70c357e9389fed14819faf79463
|
|
|
|
|
|
| |
It has been deprecated since 1.31 and it is unused.
Change-Id: I695e7f5d253076829ba9b58bccd7bfc77624c393
|
|
|
|
|
|
| |
Related to I29399e7.
Change-Id: Iafa1fcac95f9b7a6cbc3a8ae9d4aff825acb302d
|
|
|
|
|
|
| |
It has been deprecated since 1.29 and it is unused.
Change-Id: I4a737273fcf03f33ab3dc6e56e9becbdb7a79c00
|
|
|
|
|
|
| |
It has been deprecated since 1.31 and it is unused.
Change-Id: Ieb2273939fa5d4244ccf1fd4a653ec784167dfe1
|
|
|
|
|
|
| |
The property has been deprecated since 1.29.
Change-Id: I04ab2fc7aac85f448ebef3bb5bc24aa5c617f233
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reasoning:
* Not all code needs an actual User object. And even if, most code
doesn't need it to be validated. That's expensive.
Let the users decide.
* setUserObj() is almost never called anyway. And the few places that
call it go the extra mile and create a User object just to please this
setter. We can avoid or at least postpone this.
* All callers already fall back to getUser() when there is no
getUserObj().
* For a while we try to replace the User class with much smaller
interfaces, whenever possible. This is a chance to remove of one more.
* A "user IP" is a concept that doesn't even exist in this code. The
setter writes to the same property as setUsername(). This makes it
very easy to use these methods wrong, and this indeed already happened
in some places.
Change-Id: I6687305a5be68e8a068f11482625a0a6bd9626f2
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is almost always null. All callers expect this already and fall
back to getUser().
It looks like setUserObj() is sometimes called with false. Luckily the
users I can find use the ?: operator and behave the same, no matter
if they get null or false. Let's fix it anyway to make the code less
surprising.
Depends-On: Id019f633a19f925faa1e5890a9b7818bb9e81a84
Change-Id: I128c21c60f6bb017521218933c22e6f1754e9133
|
|
|
|
|
|
|
|
| |
Part 1, proof of concept. Hundreds of files left to go. These changes
brought to you in large part by vim macros.
Bug: T305805
Change-Id: I44789091e9f6394c800a11b29f22528c8dcacf71
|
|
|
|
| |
Change-Id: I301786f35cd6eb9c63fb72e0b64cffa9efd7b86b
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Queries that query a value "1" are expected to return either
that "1" (possibly as a string), or false. It's safe to simply
cast this to bool and use it as it is.
Queries for COUNT(*) are expected to return that number,
possibly as a string. It's not possible for such a query to
return false. And even if, casting to 0 is fine.
I found an existing code style where the table name and the
"1" are on the same line as the selectField() method name, and
applied it to all similar queries.
Change-Id: I9453196281871c03ef03f653f43762eb9284342f
|
|/
|
|
|
|
|
| |
It's documented as string only, but some code (possibly test code) is
passing null, causing failures for I0e7e4a48b56c3e5fde56f50693fd0cdc19c30dd0.
Change-Id: I07e2fc0c6249e8bcda3af99213fcf26f17e6df94
|
|
|
|
|
|
| |
Just an auto-replace from codesniffer for now.
Change-Id: I5240dc9ac5929d291b0ef1c743ea2bfd3f428266
|
|
|
|
|
| |
Bug: T278917
Change-Id: I1b78bad7e1fa43f5f82908567a7daad9c6cc79b9
|
|
|
|
| |
Change-Id: Ib2a74c1ac1a1902341e289961f4c1aa4dadd4bd8
|
|
|
|
|
|
| |
Use getModel() as the arg instead
Change-Id: Ie23d31885416abdcc639f4fc5028961ba80de495
|
|
|
|
|
|
|
| |
Soft deprecated since 1.31 and no longer in use save one usage
in WikiImporter which has been replaced too.
Change-Id: I88305fb7579d66fd402646f1717f2d528bf90d02
|
|
|
|
|
| |
Bug: T220525
Change-Id: I7d41a8af12e33aed802526eb39a0880292c4f534
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added:
- ContentHandlerFactory
Tests:
- PHPUnit
Changed
- Calls of changed and deprecated
- DI for some service/api
Deprecated:
- ContentHandler::* then similar to ContentHandlerFactory
- ContentHandler::getForTitle
- ContentHandler::$handlers
Bug: T235165
Change-Id: I59246938c7ad7b3e70e46c9e698708ef9bc672c6
|
|
|
|
| |
Change-Id: I90cfe8366c0245c9c67e598d17800684897a4e27
|
|
|
|
|
|
|
|
|
|
|
| |
Repeating the variable name doesn't do anything. Documentation
generators don't need it. It's more stuff to read that doesn't add new
information. And it can become outdated.
Note there are two types of @var docs. When used inline (and not on a
class property) the variable name is needed.
Change-Id: If5a520405efacd8cefd90b878c999b842b91ac61
|
|
|
|
| |
Change-Id: I5a3d6883150d63d16c1d59ae202e884acb7ec429
|
|
|
|
|
|
|
|
| |
This makes it possible to import change tags, which will be leveraged by
Extension:FileImporter.
Bug: T227849
Change-Id: I70a8df2b2be0ec11806eb8d798115c52683cc787
|
|\ |
|
| |
| |
| |
| | |
Change-Id: I3a11173bc96611c69cdc615eba741c6e4f92824a
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
UploadImporter was the name of the new class in the first patch sets of
change I4a6c573fc0, but by the time it was merged as commit 25fbfd9b9c
it had been split into an UploadRevisionImporter interface with an
ImportableUploadRevisionImporter implementation; however, not all the
references to those methods were fully updated.
Also, downloadSource() is not actually intended as a replacement method
– it was introduced, already deprecated, only to avoid going through the
deprecation process, with the intention of removing it (and making the
implementation private) once enough time had passed. Update the comments
to clarify this as well.
Change-Id: I50a07c0db102cdc98e5b7c1a176f401b87d627c9
|
|
|
|
| |
Change-Id: If9c59d432e4b8b91b8c81200bf3a8a910461eded
|