recursive update