mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-02 03:18:30 +02:00
Fix export when index already exists
This commit is contained in:
parent
37a692f942
commit
b7bebe9bbb
@ -72,8 +72,12 @@ impl IndexScheduler {
|
||||
}
|
||||
|
||||
request.send_bytes(Default::default()).map_err(into_backoff_error)
|
||||
})?;
|
||||
let index_exists = response.status() == 200;
|
||||
});
|
||||
let index_exists = match response {
|
||||
Ok(response) => response.status() == 200,
|
||||
Err(Error::FromRemoteWhenExporting { code, .. }) if code == "index_not_found" => false,
|
||||
Err(e) => return Err(e),
|
||||
};
|
||||
|
||||
let primary_key = index
|
||||
.primary_key(&index_rtxn)
|
||||
|
Loading…
x
Reference in New Issue
Block a user