fix category drop-down menu when re-rendering