From 826eb185c3c86f62112ae7b18ec746d13f6f075c Mon Sep 17 00:00:00 2001 From: sondermanish Date: Fri, 13 Dec 2024 14:11:27 +0530 Subject: [PATCH] added interface method --- .../appsmith/server/git/central/CentralGitServiceCE.java | 2 ++ .../server/git/central/CentralGitServiceCEImpl.java | 7 ++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCE.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCE.java index 576a7fb99cd..4254b5d4dd2 100644 --- a/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCE.java +++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCE.java @@ -31,4 +31,6 @@ Mono fetchRemoteChanges( ArtifactType artifactType, GitType gitType, RefType refType); + + Mono discardChanges(String branchedArtifactId, ArtifactType artifactType, GitType gitType); } diff --git a/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCEImpl.java b/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCEImpl.java index 69400d6a525..cd605372e6d 100644 --- a/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCEImpl.java +++ b/app/server/appsmith-server/src/main/java/com/appsmith/server/git/central/CentralGitServiceCEImpl.java @@ -1114,12 +1114,13 @@ private Mono updateArtifactWithGitMetadataGivenPermission( } /** - * + * Resets the artifact to last commit, all uncommitted changes are lost in the process. * @param branchedArtifactId : id of the branchedArtifact * @param artifactType type of the artifact - * @param gitType - * @return + * @param gitType what is the intended implementation type + * @return : a publisher of an artifact. */ + @Override public Mono discardChanges( String branchedArtifactId, ArtifactType artifactType, GitType gitType) {