@@ -91,7 +91,7 @@ impl PineconeClient {
91
91
} ;
92
92
93
93
// make openAPI call
94
- let res = manage_indexes_api:: create_index ( & self . openapi_config ( ) , create_index_request)
94
+ let res = manage_indexes_api:: create_index ( & self . openapi_config , create_index_request)
95
95
. await
96
96
. map_err ( |e| PineconeError :: from ( e) ) ?;
97
97
@@ -191,7 +191,7 @@ impl PineconeClient {
191
191
} ;
192
192
193
193
// make openAPI call
194
- let res = manage_indexes_api:: create_index ( & self . openapi_config ( ) , create_index_request)
194
+ let res = manage_indexes_api:: create_index ( & self . openapi_config , create_index_request)
195
195
. await
196
196
. map_err ( |e| PineconeError :: from ( e) ) ?;
197
197
@@ -244,7 +244,7 @@ impl PineconeClient {
244
244
245
245
// Gets ready status of an index
246
246
async fn is_ready ( & self , name : & str ) -> bool {
247
- let res = manage_indexes_api:: describe_index ( & self . openapi_config ( ) , name) . await ;
247
+ let res = manage_indexes_api:: describe_index ( & self . openapi_config , name) . await ;
248
248
match res {
249
249
Ok ( index) => index. status . ready ,
250
250
Err ( _) => false ,
@@ -275,7 +275,7 @@ impl PineconeClient {
275
275
/// ```
276
276
pub async fn describe_index ( & self , name : & str ) -> Result < IndexModel , PineconeError > {
277
277
// make openAPI call
278
- let res = manage_indexes_api:: describe_index ( & self . openapi_config ( ) , name)
278
+ let res = manage_indexes_api:: describe_index ( & self . openapi_config , name)
279
279
. await
280
280
. map_err ( |e| PineconeError :: from ( e) ) ?;
281
281
@@ -306,7 +306,7 @@ impl PineconeClient {
306
306
/// ```
307
307
pub async fn list_indexes ( & self ) -> Result < IndexList , PineconeError > {
308
308
// make openAPI call
309
- let res = manage_indexes_api:: list_indexes ( & self . openapi_config ( ) )
309
+ let res = manage_indexes_api:: list_indexes ( & self . openapi_config )
310
310
. await
311
311
. map_err ( |e| PineconeError :: from ( e) ) ?;
312
312
@@ -356,7 +356,7 @@ impl PineconeClient {
356
356
357
357
// make openAPI call
358
358
let res = manage_indexes_api:: configure_index (
359
- & self . openapi_config ( ) ,
359
+ & self . openapi_config ,
360
360
name,
361
361
configure_index_request,
362
362
)
@@ -390,7 +390,7 @@ impl PineconeClient {
390
390
/// ```
391
391
pub async fn delete_index ( & self , name : & str ) -> Result < ( ) , PineconeError > {
392
392
// make openAPI call
393
- let res = manage_indexes_api:: delete_index ( & self . openapi_config ( ) , name)
393
+ let res = manage_indexes_api:: delete_index ( & self . openapi_config , name)
394
394
. await
395
395
. map_err ( |e| PineconeError :: from ( e) ) ?;
396
396
@@ -431,12 +431,10 @@ impl PineconeClient {
431
431
} ;
432
432
433
433
// make openAPI call
434
- let res = manage_indexes_api:: create_collection (
435
- & self . openapi_config ( ) ,
436
- create_collection_request,
437
- )
438
- . await
439
- . map_err ( |e| PineconeError :: from ( e) ) ?;
434
+ let res =
435
+ manage_indexes_api:: create_collection ( & self . openapi_config , create_collection_request)
436
+ . await
437
+ . map_err ( |e| PineconeError :: from ( e) ) ?;
440
438
441
439
Ok ( res)
442
440
}
@@ -464,7 +462,7 @@ impl PineconeClient {
464
462
/// # }
465
463
/// ```
466
464
pub async fn describe_collection ( & self , name : & str ) -> Result < CollectionModel , PineconeError > {
467
- let res = manage_indexes_api:: describe_collection ( & self . openapi_config ( ) , name)
465
+ let res = manage_indexes_api:: describe_collection ( & self . openapi_config , name)
468
466
. await
469
467
. map_err ( |e| PineconeError :: from ( e) ) ?;
470
468
@@ -494,7 +492,7 @@ impl PineconeClient {
494
492
/// ```
495
493
pub async fn list_collections ( & self ) -> Result < CollectionList , PineconeError > {
496
494
// make openAPI call
497
- let res = manage_indexes_api:: list_collections ( & self . openapi_config ( ) )
495
+ let res = manage_indexes_api:: list_collections ( & self . openapi_config )
498
496
. await
499
497
. map_err ( |e| PineconeError :: from ( e) ) ?;
500
498
@@ -525,7 +523,7 @@ impl PineconeClient {
525
523
/// ```
526
524
pub async fn delete_collection ( & self , name : & str ) -> Result < ( ) , PineconeError > {
527
525
// make openAPI call
528
- let res = manage_indexes_api:: delete_collection ( & self . openapi_config ( ) , name)
526
+ let res = manage_indexes_api:: delete_collection ( & self . openapi_config , name)
529
527
. await
530
528
. map_err ( |e| PineconeError :: from ( e) ) ?;
531
529
0 commit comments