Small fixes

Send resource when it is clicked and not only when the client asks for
it.