Fix generation of link edit