Fixed the display bugs