Esempio n. 1
0
function s3_uploads_init()
{
    if (!s3_uploads_check_requirements()) {
        return;
    }
    if (!defined('S3_UPLOADS_BUCKET')) {
        return;
    }
    if ((!defined('S3_UPLOADS_KEY') || !defined('S3_UPLOADS_SECRET')) && !defined('S3_UPLOADS_USE_INSTANCE_PROFILE')) {
        return;
    }
    if (!s3_uploads_enabled()) {
        return;
    }
    $instance = S3_Uploads::get_instance();
    $instance->setup();
}
Esempio n. 2
0
function s3_uploads_init()
{
    if (!s3_uploads_check_requirements()) {
        return;
    }
    if (!defined('S3_UPLOADS_BUCKET')) {
        return;
    }
    if ((!defined('S3_UPLOADS_KEY') || !defined('S3_UPLOADS_SECRET')) && !defined('S3_UPLOADS_USE_INSTANCE_PROFILE')) {
        return;
    }
    if (!s3_uploads_enabled()) {
        return;
    }
    if (!defined('S3_UPLOADS_REGION')) {
        wp_die('S3_UPLOADS_REGION constant is required. Please define it in your wp-config.php');
    }
    $instance = S3_Uploads::get_instance();
    $instance->setup();
}