Corrected NPE issue on load.