Well mass-moderation stuff like that is generally a little server intensive, why do you think update counters has you set limits on users to process per run? Because its like 5 queries per person :-p Same thing here. I tried to keep it as small as possible whenever that happens.
The main problem this time was I did not think a certain function was called on every single post, which means a query I stuck in there was. I moved it out of that function and it works the same without that extra query every time.
Also, credits can go negative because it was the only way it can function as correctly as possible. By its very nature pretty much everything can be exploited. What if you made long posts for post size credits, bought something with them, and then trimmed your post to normal? It needs to go negative so at least they will pay back what they technically stole. Plus theres settable amounts for having a post deleted, so you could in fact punish users for writing something that got deleted, so making them work it back is kind of ideal.
|