Fix exception and more