Stabilization of terpyridine covered gold nanoparticles by metal ions complexation