prevent NPE on getCookies