github.com/blend/go-sdk@v1.20220411.3/r2/opt_posted_files.go (about)

     1  /*
     2  
     3  Copyright (c) 2022 - Present. Blend Labs, Inc. All rights reserved
     4  Use of this source code is governed by a MIT license that can be found in the LICENSE file.
     5  
     6  */
     7  
     8  package r2
     9  
    10  import "github.com/blend/go-sdk/webutil"
    11  
    12  // OptPostedFiles adds multipart uploads to the request.
    13  //
    14  // Usage note: this option will also encode any currently provided
    15  // post form fields into the body as well, so you should make this the
    16  // last option in a list to capture those fields.
    17  func OptPostedFiles(files ...webutil.PostedFile) Option {
    18  	return RequestOption(webutil.OptPostedFiles(files...))
    19  }