Added protection against junk values