finished server side validation