Use material from GLB in custom shader

Thanks, but I didn’t get how how to retrieve the texture from child.material . I’m following the example I found here, but with this mesh, the field child.material.map is null. Which field in the material structure should I use ?