remove nullpointer when harble api not uptodate

This commit is contained in:
sirjonasxx 2019-01-18 14:02:34 +01:00
parent 75e92d4a3b
commit 459f07e126
2 changed files with 3 additions and 3 deletions

View File

@ -198,6 +198,6 @@ public class HarbleAPI {
if (Cacher.cacheFileExists(cachedMessagesPath)) {
return Cacher.getCacheDir() + File.separator + cachedMessagesPath;
}
return super.toString();
return "null";
}
}

View File

@ -158,7 +158,7 @@ public class Extensions extends SubForm {
.appendString(getHConnection().getDomain())
.appendInt(getHConnection().getPort())
.appendString(getHConnection().getHotelVersion())
.appendString(HarbleAPIFetcher.HARBLEAPI.toString())
.appendString(HarbleAPIFetcher.HARBLEAPI + "") // automatic .toString() and no additional nullpointerexception
);
}
}
@ -295,7 +295,7 @@ public class Extensions extends SubForm {
.appendString(getHConnection().getDomain())
.appendInt(getHConnection().getPort())
.appendString(getHConnection().getHotelVersion())
.appendString(HarbleAPIFetcher.HARBLEAPI.toString())
.appendString(HarbleAPIFetcher.HARBLEAPI + "")
);
}