I only added if statement around this block of code.