mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[hg] rename according to code conventions and simplify
This commit is contained in:
@@ -61,6 +61,6 @@ public final class HgErrorUtil {
|
||||
if (StringUtil.isEmptyOrSpaces(destinationPath)) {
|
||||
return false;
|
||||
}
|
||||
return HgUtil.reposirotyUrlWithPasswordPattern.matcher(destinationPath).matches();
|
||||
return HgUtil.URL_WITH_PASSWORD.matcher(destinationPath).matches();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ import java.util.regex.Pattern;
|
||||
*/
|
||||
public abstract class HgUtil {
|
||||
|
||||
public static final Pattern reposirotyUrlWithPasswordPattern = Pattern.compile("(.+):(.+)@(.+)");
|
||||
public static final Pattern URL_WITH_PASSWORD = Pattern.compile("(.+):(.+)@(.+)");
|
||||
public static final int MANY_FILES = 100;
|
||||
private static final Logger LOG = Logger.getInstance(HgUtil.class);
|
||||
|
||||
@@ -477,7 +477,7 @@ public abstract class HgUtil {
|
||||
}
|
||||
|
||||
public static String removePasswordIfNeeded(@NotNull String path) {
|
||||
Matcher matcher = reposirotyUrlWithPasswordPattern.matcher(path);
|
||||
Matcher matcher = URL_WITH_PASSWORD.matcher(path);
|
||||
if (matcher.matches()) {
|
||||
return matcher.group(1) + "@" + matcher.group(3);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user