Resolve code smells in `getFiles` receiving branch but using ref
The following discussion from !19348 (merged) should be addressed:
-
@pslaughter started a discussion: (+2 comments) thought: It's a little smelly that we're concerned about
selectedBranch
being falsey, but go ahead and useref
like we're guaranteed it's truthy... This is a symptom of some underlying design issues (like, why even passbranchId
into here if we're really wanting to fetch based on the ref)🤔 I'd like to see us explore redefining this function to just
getFiles({ ... }, ref)
, and see what other design issues we can unravel. I'll create a follow up issue from this.