fix for nested models