change add_flg API: flg is always required