From 1e7ee722409821a3d23174ce7d8b434970da1b77 Mon Sep 17 00:00:00 2001 From: reger Date: Sun, 23 Nov 2014 23:29:20 +0100 Subject: [PATCH] fix path lookup to ./defaults/yacy.badwords (fix of commit https://gitorious.org/yacy/rc1/commit/ee277b9b3e033e8261a97b8334b79059220f113a) --- source/net/yacy/search/Switchboard.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/net/yacy/search/Switchboard.java b/source/net/yacy/search/Switchboard.java index 1202c11d6..35aed07cd 100644 --- a/source/net/yacy/search/Switchboard.java +++ b/source/net/yacy/search/Switchboard.java @@ -633,9 +633,9 @@ public final class Switchboard extends serverSwitch { // load badwords (to filter the topwords) if ( badwords == null || badwords.isEmpty() ) { - File badwordsFile = new File(appPath, "/DATA/SETTINGS/" + SwitchboardConstants.LIST_BADWORDS_DEFAULT); + File badwordsFile = new File(appPath, "DATA/SETTINGS/" + SwitchboardConstants.LIST_BADWORDS_DEFAULT); if (!badwordsFile.exists()) { - badwordsFile = new File(appPath, SwitchboardConstants.LIST_BADWORDS_DEFAULT); + badwordsFile = new File(appPath, "defaults/" + SwitchboardConstants.LIST_BADWORDS_DEFAULT); } badwords = SetTools.loadList(badwordsFile, NaturalOrder.naturalComparator); // badwordHashes = Word.words2hashesHandles(badwords); @@ -649,7 +649,7 @@ public final class Switchboard extends serverSwitch { // load stopwords (to filter query and topwords) if ( stopwords == null || stopwords.isEmpty() ) { - File stopwordsFile = new File(dataPath, "/DATA/SETTINGS/" + SwitchboardConstants.LIST_STOPWORDS_DEFAULT); + File stopwordsFile = new File(dataPath, "DATA/SETTINGS/" + SwitchboardConstants.LIST_STOPWORDS_DEFAULT); if (!stopwordsFile.exists()) { stopwordsFile = new File(appPath, "defaults/"+SwitchboardConstants.LIST_STOPWORDS_DEFAULT); }