[21:13:57] Didn't get a response last night, so I'm going to ask this again. I want to make sure this is the proper way to get a user and check a permission in an extension: https://pastebin.com/jj12y8sy [21:14:31] From what I understand, it seems like $wgUser was deprecated because it's possible for it to not be properly populated in some contexts [21:14:50] So if I have this right, we should be getting the user from the current instance. [21:15:25] Don't mind the "checkemail" right; it's a custom one from an extension. [21:20:08] In addition, I've seen that the Revision class is hard deprecated as of 1.35 with instructions to use RevisionStore, BlobStore, or RevisionRecord. I have not been able to find an equivalent to the old function Revision::newFromTitle(), however. I figured RevisionStore was probably what I was looking for, but now I'm not sure. [21:32:14] jfolv: looks about right (though I for one wasn't aware of that way of getting a User object, but figures); re:Revision, maybe try $instance->getRevisionStoreFactory()->getRevisionStore()->getRevisionByTitle( $title ) ? it's what one of the (crazy) extensions I maintain does, though that extension intentionally connects to a non-$wgDBname database, hence the complexity [22:06:15] jfolv: we're moving away from all global variables little by little. where it's possible to inject the factory into the constructor, that's preferred. there are some rough notes/docs about this here: https://www.mediawiki.org/wiki/Dependency_Injection [22:21:09] it's preferred that folks use RevisionStore instead of RevisionRecord if you need an instance of one of those, and you should not need to use a BlobStore directly, the RevisionStore should do that for you, you get an instance of that via MediaWikiServices too [22:21:13] hope that makes sense