Avoid override record link
Remove obsolete code + jshint
Hide link if record is a draft