Delete old links before inserting new ones.