fixed bug in display.lua