Add support for expected_old_oid to avoid race conditions when deleting branches
What does this MR do and why?
By passing the expected old object ID, we ensure that the branch has not been updated by another client during the deletion process. This change enhances the reliability and consistency of branch deletion operations, mitigating potential data integrity issues caused by concurrent updates. Additionally, tests have been updated to verify the correct handling of this parameter and related error cases
Screenshots or screen recordings
Edited by Emma Park


