Fixed malformated return of insert_links