diff --git a/lib/gitlab/ee_compat_check.rb b/lib/gitlab/ee_compat_check.rb
index 0829c1c318e8cb7486d0791888f4ea974eb9cc13..496ee0bdcb03a50f2b29541f1f04751e7bde1b24 100644
--- a/lib/gitlab/ee_compat_check.rb
+++ b/lib/gitlab/ee_compat_check.rb
@@ -125,7 +125,7 @@ module Gitlab
       end
 
       puts
-      puts applies_cleanly_msg(ee_branch)
+      puts applies_cleanly_msg(ee_branch_found)
     end
 
     def check_patch(patch_path)
@@ -215,7 +215,7 @@ module Gitlab
     end
 
     def ee_patch_name
-      @ee_patch_name ||= patch_name_from_branch(ee_branch)
+      @ee_patch_name ||= patch_name_from_branch(ee_branch_found)
     end
 
     def ee_patch_full_path