fixing printing issue