Added possibility to retrieve realm from instance