Fixed S3 upload issue