Implemented return server functionallity
TODO: fix neigbour set bug, by using keys instead of pointers