pseudo code: flag child metadata