wikimedia-gadgets / afc-helper

A tool for reviewing Articles for Creation submissions on the English Wikipedia
https://en.wikipedia.org/wiki/Wikipedia:AFCH
GNU General Public License v3.0
37 stars 80 forks source link

Allow admins to use the script (#130) #231

Closed kzhovn closed 2 years ago

kzhovn commented 2 years ago

I set a AFCH.const.userSysop and checked against that. Obviously I'm not an admin and testwiki lets anyone use the script anyway, so this hasn't been tested except to confirm that AFCH.const.userSysop returns false for me.

I assume it's fine to take this issue given that the person assigned it hasn't commented there in a year, but let me know if this is some kind of horrible etiquette violation.

NovemLinguae commented 2 years ago

Fixes #130

edit: Linking this PR to issue 130 didn't work. Someone with more access will likely want to link this to issue #130, so accepting this PR auto closes the issue.

NovemLinguae commented 2 years ago

I'm an admin on testwiki. I changed whitelistRequired to true and tested it out. Tested and working.

enterprisey commented 2 years ago

Thanks for the contribution. Hmm... do you think it might be nicer to just use the $.inArray call instead of the variable? I feel like it might be simpler. (That is, replacing the two existing uses of AFCH.consts.userSysop with the $.inArray( ... ) call.)

kzhovn commented 2 years ago

I don't have a strong preference, happy to change it.

enterprisey commented 2 years ago

OK, please change it and then otherwise it looks good to me, thanks again.

kzhovn commented 2 years ago

Done, sorry for the delay, I had a guest this week and that bumped a lot off my todo list.

kzhovn commented 2 years ago

Is there any estimate on when this might be merged/what's holding it up? Happy to do more work if needed. Normally I wouldn't want to bother people but I have a couple months before starting work and would like to make some further progress while I have some spare time, but don't want to start with six unmerged PRs.

NovemLinguae commented 2 years ago

I think @enterprisey is probably busy in real life. I think you can keep submitting PRs, they'll be responded to eventually. If anyone wants to give me +2, I'm happy to test and merge simple PRs.

IngenuityWP commented 2 years ago

Doesn't look like there are any problems with this, merging.

NovemLinguae commented 2 years ago

An admin reports that this patch didn't work. This may need further tweaking.

The new version to let admins use afch didn't work, at least for me. I reverted to the previous version --DGG

https://en.wikipedia.org/wiki/Wikipedia_talk:WikiProject_Articles_for_creation#participant_list

kzhovn commented 2 years ago

It looks like other admins aren't having the same issue. If it's not caching or something like that I'm not sure how to go about debugging, it's basically just "if on list of participants OR admin, let them use the script" and I'm not sure how to replicate the issue. I've asked DDG to try bypass his cache and check if it's a problem with one of his other userscripts.