Follow-up from "Refactor root sha access code"
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
The following discussion from !112289 (merged) should be addressed:
-
@mhamda started a discussion: (+1 comment)
Problem
Method #root_ref_sha is used in multiple places, but it is not safe to use. For example, it can raise an exception if repository is empty.
Proposal
- Verify commit existence and return
nilinstead of an exception. - Test and update, if necessary, all cases where the method is used. (if the code relies on the exception, then update it to handle
nilvalue)
Edited by 🤖 GitLab Bot 🤖