diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/journal/jn.js b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/journal/jn.js index 7be48f1e04..260615b0e2 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/journal/jn.js +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/journal/jn.js @@ -61,7 +61,9 @@ function workaround(journals) { for (var i in journals){ - journals[i]['NameService']= journals[i]['modelerType'].split("-")[1]; + var str= journals[i]['modelerType']; + var index= str.indexOf("-"); + journals[i]['NameService']= str.substr(index + 1); } return journals;