stadust / pointercrate

Rewrite of the https://pointercrate.com backend in Rust
MIT License
78 stars 50 forks source link

Fix mods only being able to verify own claims #62

Closed stadust closed 2 years ago

stadust commented 2 years ago

Opening this as a PR since I made the changes through the web interface and I have no idea whether or not I wrote syntactically correct Rust code.

But essentially we fix a logic error in the code that checks whether a user is allowed to patch a player claim. The previous code would always require the person performing the claim to actually own the claim, but this is only required if you patch the lock_submissions field. This broke verification, as obviously pointercrate mods do not own the claims they verify