updated to require fs for upload directory creation.