Improved linkcleanup