Added JS error catch when adding links to a project

The page was failing silently when adding a link to a project didn't work - the form cleared and the links reloaded as they should do, but without the new link.

Now, if the API returns a failure the user at least gets a pop up saying so..