display: fix undefined variables judge