em.close in finally