Commit graph

7 commits

Author SHA1 Message Date
daniel
4dce6dd0c3 Deprecate UserIdentity::getActorId()
Note: User::getActorId() is not (yet) deprecated.

Bug: T274179
Change-Id: Ic2ca6d489db821fc2334e53bf2496c7b0d3ea5b1
2021-03-13 19:45:57 +01:00
daniel
7e2f7efa27 Convert Language to UserIdentity
This also introduces minimal instance caching into UserFactory

Change-Id: I594c5668c537477516dda4beecd11b8aa840ae62
2021-03-11 20:23:23 +01:00
Petr Pchelko
30cf40568b Add Authority to Context
Bug: T271460
Change-Id: If1038c94ccf8f3e59b5242f5c33b66f076c60816
2021-01-20 09:07:27 -06:00
DannyS712
e9c0f8236c Migrate more User::newFrom* methods to UserFactory
Bug: T253432
Depends-On: If5e76f2ae570ef4ae58cb77b5281c4446a1cadff
Change-Id: I9286d4a69911a84661cba40c55c0a4e3f1b7f7f3
2020-10-05 23:47:53 +00:00
DannyS712
4db93b3be4 Inject dependencies into PasswordReset, and cleanup
* Convert everything that is protected to be private,
since the class is not stable to extend

* Remove PasswordReset::$hookContainer, unneeded

Additionally, add missing UserFactory::newFromRow,
for now just a wrapper for User::newFromRow

Bug: T253432
Change-Id: I1de57a08605ff6e0d2be8e276b7fcb08934fb5da
2020-10-03 00:23:59 +00:00
Nikki Nikkhoui
6c8187d4f8 UserFactory method for getting anonymous user
Create a method in UserFactory to instantiate an anonymous
user with an optional IP address.

Bug: T257464
Change-Id: I557620f9bcd4b646288b4a76b26c4730fccbc3d8
2020-07-15 00:07:45 +00:00
DannyS712
61a3a8f734 UserFactory v.1 - wrapper for User::newFrom* static methods
Makes it possible to mock static User methods in tests;
actually introducing dependency injection to the User class is left for
the future.

New class has 100% code coverage

Bug: T253432
Change-Id: I0b93da09124d95beafd84e932b214909ce920230
2020-06-10 20:38:26 -07:00