diff --git a/scm-plugins/scm-hg-plugin/src/main/java/sonia/scm/repository/HgHookManager.java b/scm-plugins/scm-hg-plugin/src/main/java/sonia/scm/repository/HgHookManager.java index 795e01c22b..dc709f71b3 100644 --- a/scm-plugins/scm-hg-plugin/src/main/java/sonia/scm/repository/HgHookManager.java +++ b/scm-plugins/scm-hg-plugin/src/main/java/sonia/scm/repository/HgHookManager.java @@ -54,9 +54,6 @@ import sonia.scm.util.Util; import java.io.IOException; -import java.net.HttpURLConnection; -import java.net.URL; - import java.util.UUID; import javax.servlet.http.HttpServletRequest; @@ -89,7 +86,7 @@ public class HgHookManager implements ConfigChangedListener */ @Inject public HgHookManager(ScmConfiguration configuration, - Provider httpClientProvider) + Provider httpClientProvider) { this.configuration = configuration; this.configuration.addListener(this); @@ -180,7 +177,7 @@ public class HgHookManager implements ConfigChangedListener if (logger.isDebugEnabled()) { logger.debug( - "create hook url from configured base url because force base url is enabled"); + "create hook url from configured base url because force base url is enabled"); } hookUrl = createConfiguredUrl(); @@ -204,8 +201,8 @@ public class HgHookManager implements ConfigChangedListener if (logger.isWarnEnabled()) { logger.warn( - "hook url {} from request does not work, try now localhost", - hookUrl); + "hook url {} from request does not work, try now localhost", + hookUrl); } hookUrl = createLocalUrl(request); @@ -215,8 +212,8 @@ public class HgHookManager implements ConfigChangedListener if (logger.isWarnEnabled()) { logger.warn( - "localhost hook url {} does not work, try now from configured base url", - hookUrl); + "localhost hook url {} does not work, try now from configured base url", + hookUrl); } hookUrl = createConfiguredUrl(); @@ -239,7 +236,7 @@ public class HgHookManager implements ConfigChangedListener private String createConfiguredUrl() { return HttpUtil.getUriWithoutEndSeperator( - configuration.getBaseUrl()).concat("/hook/hg/"); + configuration.getBaseUrl()).concat("/hook/hg/"); } /** @@ -269,8 +266,8 @@ public class HgHookManager implements ConfigChangedListener if (logger.isErrorEnabled()) { logger.error( - "disabling mercurial hooks, because hook url {} seems not to work", - hookUrl); + "disabling mercurial hooks, because hook url {} seems not to work", + hookUrl); } hookUrl = Util.EMPTY_STRING;