Campers used to be able to delete pledges, but this important functionality somehow recently broke.
Steps to reproduce:

The way we are fixing this manually is by adding a "formerUserId" property set to the value of "userId", and then setting "userId" itself null.
edit(@berkeleyTrue): removed extra information as it just confuses the issue
@gasperno please ignore that bit of information. The issue is why is it throwing an error and why is it not correctly modifying the pledge object.
I don't think you've gotten to the core of the issue. You did find a bug, but not the one responsible here. The error we are seeing is an 'oops' error, meaning an actual error was thrown in production and caught by the server, causing the oops error to be shown.
In development the server will actually print out the error stack as a page when that happens.
@BerkeleyTrue My code was not updated. Sorry for the confusion.
Edit: I deleted my irrelevant comments. Others who want to handle this issue might get confused by my questions/analysis.
This is my first Open Source contribution! I fixed this bug in PR #8824
Feedback is appreciated.