fixed add link and code failed bug