Fixed bug in log uploading