Revert "Do not override the ref passed to checkout."

This reverts commit bd8ce25cbd5cf234f227669c99d7671a48acd596.

Reason for revert: This change didn't work as the second checkout is for the flutter repository.

Original change's description:
> Do not override the ref passed to checkout.
>
> A second call to checkout will fail for a different repository. E.g.
> cocoon recipe checks out cocoon and then checks out flutter/flutter. The
> second checkout fails because is trying to use cocoon commit.
>
> Change-Id: I2e308fe8247e8cc365d3606a44bf780f79aea767
> Reviewed-on: https://flutter-review.googlesource.com/c/recipes/+/37601
> Reviewed-by: Yusuf Mohsinally <mohsinally@google.com>
> Commit-Queue: Godofredo Contreras <godofredoc@google.com>

TBR=godofredoc@google.com,flutter-scoped@luci-project-accounts.iam.gserviceaccount.com,mohsinally@google.com

Change-Id: I6e4be5d99596f19193304f30729742bbf41c1e4f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://flutter-review.googlesource.com/c/recipes/+/37640
Commit-Queue: Godofredo Contreras <godofredoc@google.com>
Reviewed-by: Godofredo Contreras <godofredoc@google.com>
diff --git a/recipe_modules/repo_util/api.py b/recipe_modules/repo_util/api.py
index c52258d..60a66d6 100644
--- a/recipe_modules/repo_util/api.py
+++ b/recipe_modules/repo_util/api.py
@@ -228,13 +228,8 @@
       # gitiles_commit.id is more specific than gitiles_commit.ref, which is
       # branch
       # if this a release build, self.m.buildbucket.gitiles_commit.id should have more priority than
-      # ref since it is more specific, and we don't want to default to
-      # refs/heads/<REPO_BRANCHES[name]>
-
-      # Do not override ref for cocoon. Cocoon recipes checkouts multiple repositories and trying to
-      # override will try to use the commit for the repository triggering the build. e.g. Cocoon
-      # recipe checks out cocoon repo, and then checkouts flutter trying to use the cocoon commit.
-      if (ref in ['refs/heads/beta', 'refs/heads/stable']) and (name != 'cocoon'):
+      # ref since it is more specific, and we don't want to default to refs/heads/<REPO_BRANCHES[name]>
+      if ref in ['refs/heads/beta', 'refs/heads/stable']:
         git_ref = (
             self.m.buildbucket.gitiles_commit.id or
             self.m.buildbucket.gitiles_commit.ref or ref