Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions restapi/user_objects.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,6 @@ func registerObjectsHandlers(api *operations.ConsoleAPI) {

// getListObjectsResponse returns a list of objects
func getListObjectsResponse(session *models.Principal, params user_api.ListObjectsParams) (*models.ListObjectsResponse, *models.Error) {
ctx, cancel := context.WithTimeout(context.Background(), time.Second*20)
defer cancel()
var prefix string
var recursive bool
var withVersions bool
Expand All @@ -151,7 +149,7 @@ func getListObjectsResponse(session *models.Principal, params user_api.ListObjec
// defining the client to be used
minioClient := minioClient{client: mClient}

objs, err := listBucketObjects(ctx, minioClient, params.BucketName, prefix, recursive, withVersions)
objs, err := listBucketObjects(params.HTTPRequest.Context(), minioClient, params.BucketName, prefix, recursive, withVersions)
if err != nil {
return nil, prepareError(err)
}
Expand Down