FoxxMD / context-mod

an event-based, reddit moderation bot built on top of snoowrap and written in typescript
https://contextmod.dev
MIT License
49 stars 11 forks source link

Implement fixed iteration order for criteria to reduce api usage #92

Closed FoxxMD closed 2 years ago

FoxxMD commented 2 years ago

Criteria (author, item) can use

Currently CM iterates criteria based on how they are configured by the user. However this is non-optimal as the user (probably) does not know which criteria require api calls and which do not.

We can easily re-order the criteria to test before iterating the criteria object in order to test all criteria which do not require api calls first.