Fix metadata to be parent stack id.