diff --git a/c/src/connection.rs b/c/src/connection.rs index e36f816feb..33be4ce662 100644 --- a/c/src/connection.rs +++ b/c/src/connection.rs @@ -45,10 +45,7 @@ pub extern "C" fn connection_open_cloud( credential: *const Credential, ) -> *mut Connection { let addresses: Vec<&str> = string_array_view(addresses).collect(); - try_release(Connection::new_cloud( - &addresses, - borrow(credential).clone(), - )) + try_release(Connection::new_cloud(&addresses, borrow(credential).clone())) } /// Open a TypeDB Driver to TypeDB Cloud server(s) available at the provided addresses, using @@ -65,13 +62,9 @@ pub extern "C" fn connection_open_cloud_translated( translated_addresses: *const *const c_char, credential: *const Credential, ) -> *mut Connection { - let addresses: HashMap<&str, &str> = string_array_view(advertised_addresses) - .zip(string_array_view(translated_addresses)) - .collect(); - try_release(Connection::new_cloud_address_map( - addresses, - borrow(credential).clone(), - )) + let addresses: HashMap<&str, &str> = + string_array_view(advertised_addresses).zip(string_array_view(translated_addresses)).collect(); + try_release(Connection::new_cloud_address_map(addresses, borrow(credential).clone())) } /// Closes the driver. Before instantiating a new driver, the driver that’s currently open should first be closed.