Fix bug with null type