file upload working, other cleanup