fixed NullPointerExcpection in Dictionary class; still gives an Exception