From 52de7774376eba133dca5c290f1acb8e6f8d4ae4 Mon Sep 17 00:00:00 2001 From: kushthedude Date: Fri, 28 Feb 2020 00:22:33 +0530 Subject: [PATCH] fix: Browser redirection for 0.0.0.0 Signed-off-by: kushthedude --- server/src/com/google/refine/Refine.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/server/src/com/google/refine/Refine.java b/server/src/com/google/refine/Refine.java index e0183fe85..d57b96ae9 100644 --- a/server/src/com/google/refine/Refine.java +++ b/server/src/com/google/refine/Refine.java @@ -463,8 +463,11 @@ class RefineClient extends JFrame implements ActionListener { public void init(String host, int port) throws Exception { - uri = new URI("http://" + host + ":" + port + "/"); - + String cleanedHost = host; + if("0.0.0.0".equals(host)) { + cleanedHost = "localhost"; + } + uri = new URI("http://" + cleanedHost + ":" + port + "/"); openBrowser(); }