bug fix: newly inserted entities got no type