Commit graph

12 commits

Author SHA1 Message Date
Umherirrender
769bdbf091 docs: Fix nullable documentation for class properties
Change-Id: I6d0577124d852103f485ffdc819876a13f6641c3
2021-09-24 00:54:53 +00:00
Petr Pchelko
005160df54 Make RevisionAccessException normalized
Change-Id: I92d2418d728473d3d13719bc6e6112ab55bb797f
2021-07-15 21:49:17 -07:00
DannyS712
47d70dbfba Post Revision-removal cleanup
Updates for the removal of the Revision class itself
and the various methods/hooks/variables removed in the
process, including:

- Update some documentation removing most references
to the Revision class and updating the MCR migration
notes to reflect the past tense for Revision methods.

- Change some capitalization from "Revision" to "revision"
to make it clear comments are about revisions in general,
not the Revision class in particular.

- Minor code tweaks including removing unused variables that
were around for the old hooks that were removed, and
removing the use of DeprecatablePropertyArray where no
longer needed for anything.

- Fix incorrect documentation for PageUpdater::getStatus(),
the status value changed a while ago to have revision-record
in addition to revision, and recently to only have the
revision-record, but ironically PageUpdater was never updated.

- Removed Parser::$mRevisionObject, used to be a Revision object
and was deprecated in 1.35, missed earlier because it was no
longer being set to Revision objects, always null.

- Add RevisionRecord typehints in DummyLinker to match those
in the corresponding Linker methods

This should be a no-op in terms of functionality.

Bug: T247143
Change-Id: I03bbb94fc29085855448780b1a5ad9063911ecc4
2021-06-24 00:32:39 +00:00
Peter Ovchyn
b171edc200 Remove mentions of dbDomain from RevisionStore, RevisionRecord
In this patch I replaced RevisionStore::$dbDomain to
RevisionStore::$wikiId, RevisionRecord::$mWiki to
RevisionRecord::$wikiId and changed all hierarchies
and tests accordingly

Bug: T272901
Change-Id: I439515cfb6aa8a8697c2a5a0458ec8925522363a
2021-02-05 22:42:40 +02:00
Petr Pchelko
1fb76fefbb Change RevisionStoreCacheRecord callback signature
In order to convert the tests into tru unit tests.

Bug: T272669
Change-Id: I6055b43381fdcc6dcdf69e9311979db0dccdb16b
2021-01-26 15:14:35 +00:00
Petr Pchelko
816e02ae51 Convert RevisionRecord to Authority and PageIdentity
As we convert the RevisionRecord to using Authority,
we no longer need Title instances, so we can convert
that to PageIdentity.

Ideally, we'd part away from using Title at all, but:
1. For foreign wikis PageIdentity has stronger validation,
so calling PageIdentity getId() on Title will break things.
There's still a lot of code depending on lax Title guarantees,
so we keep it.
2. A lot of code still depends on Title, so we try to pass it
through even if we don't nesessarily need to, to save cost
on recreating it later on.

Bug: T271458
Depends-On: I287400b967b467ea18bebbb579e881a785a19158
Change-Id: I63d9807264d7e2295afef51fc9d982447f92fcbd
2021-01-21 13:37:01 -06:00
Umherirrender
ba15428253 Change object to stdClass type hints in revision related classes
Change-Id: If8fe228512abbc974369b3c10ebe9063cf136cfb
2020-11-17 22:07:29 +01:00
James D. Forrester
4f2d1efdda Coding style: Auto-fix MediaWiki.Classes.UnsortedUseStatements.UnsortedUse
Change-Id: I94a0ae83c65e8ee419bbd1ae1e86ab21ed4d8210
2020-01-10 09:32:25 -08:00
Umherirrender
6c814bb469 Set method visibility for constructor in Revision namespace
Change-Id: I79b05a0555cbd555474100675a51120f59b511e6
2019-11-30 23:41:39 +01:00
Umherirrender
2664eeb632 Clean up spacing of doc comments
Align the doc stars and normalize start and end tokens

Change-Id: Ib0d92e128e7b882bb5b838bd00c74fc16ef14303
2019-08-05 22:29:50 +00:00
Aaron Schulz
ca00e47f53 revision: rename various $wikiId fields/parameters to $dbDomain
These fields are passed to methods like LoadBalancer::getConnection() and are
already expected to be DB domains. Update various comments as well.

Fix a few minor IDEA warnings.

Change-Id: I7cf76700690aec449872a80d30b5ba540d2bf315
2019-06-28 21:30:25 +00:00
Bill Pirkle
276bf4a76b Avoid using stale data for revision visibility and actor data
Created class RevisionStoreCacheRecord to avoid returning stale
cached revision visibility and actor data when changes were
made after the cache was populated for that revision.

Bug: T216159
Change-Id: Iabed80e06a08ff0793dfe64db881cbcd535cb13f
2019-03-10 15:34:44 -05:00