From 0ce105f2f07d226cec9c4b01090cdf03d3a4fa76 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=A9bastien=20Gaya?= <sebastien.gaya@gmail.com>
Date: Thu, 30 May 2024 16:33:51 +0200
Subject: [PATCH] tree item removal if path is different (#1951)

---
 app/services/git/providers/github.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/services/git/providers/github.rb b/app/services/git/providers/github.rb
index 3a3ee2d9d..e371f2ddf 100644
--- a/app/services/git/providers/github.rb
+++ b/app/services/git/providers/github.rb
@@ -24,7 +24,7 @@ class Git::Providers::Github < Git::Providers::Abstract
       mode: file[:mode],
       type: file[:type],
       sha: nil
-    }
+    } unless path_to_check == path
     batch << {
       path: path,
       mode: file[:mode],
-- 
GitLab