Fixed NPE error on new systems;

This commit is contained in:
Oleg Agafonov 2019-04-24 18:03:53 +04:00
parent e885bd0e02
commit 43ebdf9e94

View file

@ -200,8 +200,10 @@ public class WhatsNewDialog extends MageDialog {
}.getType(); }.getType();
try { try {
httpCookies = gson.fromJson(sourceValue, type); httpCookies = gson.fromJson(sourceValue, type);
for (HttpCookie cookie : httpCookies) { if (httpCookies != null) {
store.add(URI.create(cookie.getDomain()), cookie); for (HttpCookie cookie : httpCookies) {
store.add(URI.create(cookie.getDomain()), cookie);
}
} }
} catch (Exception e) { } catch (Exception e) {
logger.error("Wrong news page cookies", e); logger.error("Wrong news page cookies", e);