processwire-issues
processwire-issues copied to clipboard
Argument #1 ($page) must be of type ProcessWire\User, ProcessWire\Page given
Short description of the issue
If you try to visit: /access/users/edit/?id=xxxx where the ID is that of a valid page, rather than a user, then you get this error in ProcessUser.module on line 352
Expected behavior
I would expect to see the "Unknown Page" error like you do when the ID is for a page that doesn't exist at all.
Actual behavior
The error noted in the title
Also, just wondering - if you try to edit a page via page/edit/?id=xxxx but the ID is for a user then it redirects to /access/users/edit/?id=xxxx. Should it also work in reverse?