updates models with relations