Tidy up; add const; working on server