jetpack_upload_handler_can_upload

jetpack_upload_handler_can_upload

Hook Type: filter

See hook in core

Displaying hooks found in version: jetpack.13.2.1

apply_filters('jetpack_upload_handler_can_upload') is found 1 times:

  • /class.jetpack.php line 3573
    		 *
    		 * @param bool|WP_Error $allowed If false or WP_Error, block the upload. If true, allow the upload.
    		 * @param mixed $_FILES The $_FILES attempting to be uploaded.
    		 */
    		$can_upload = apply_filters( 'jetpack_upload_handler_can_upload', true, $_FILES );
    		if ( ! $can_upload || is_wp_error( $can_upload ) ) {
    			if ( is_wp_error( $can_upload ) ) {
    				return $can_upload;
    			}
    			return new WP_Error( 'handler_cannot_upload', __( 'The upload handler cannot upload files', 'jetpack' ), 400 );
    		}