update folder hierarchy