server side now sort of works