Fix for S3 support