Cleanup Script will not work

Today I tested the Cleanup Script, but without success. Is there any hint? I only get a white page, without any notices or warnings.

I’ll check.

If you just get a white page, there’s probably nothing to do… I should probably add an else Statement to print something if nothing is done.

Edit: I’ve just updated it, it now tells you that nothing was done when nothing was done.

Let me know if you still get a blank page after the change.

Now it works!! Seems there was a Bug before. Now I got several messages, some pages were updated, some not :slight_smile:

No, there was no bug, the collection was set to a files collection, not to a pages collection (you can use the script for both pages and files and have to set the $collection variable accordingly) and there was no output if there was nothing to update.

Ahh ok, I was wondering why the Collection goes to files, but thought it was cause we want to check the .txt. In this case it’s clear now. Thanks so much

Another thing about this script:

When authenticating as almighty, it says I cannot edit this page - when impersonating a real user, I could update like 12 pages and then it went back to “You cannot edit”, and nothing I could do about it …

Guess I have to test this…

@S1SYPHOS Could you please provide more information about this error (stack trace)?