fixed possible NPE