remove realm when realm is not set