What if the edit is resolved and removed from the Edits table sometime AFTER the user clicks "Cancel" and the time when this code runs? It looks like nothing happens, but the user will likely be confused since the edit they tried to cancel still got applied...