Error checking for the display method of the output