fix a viewer bug