fix bug with pdf thumbnail