Commit 2c877a6d authored by Fabrice Marsaud's avatar Fabrice Marsaud

Prevent a strange problem with folder creation

parent 8b587acb
...@@ -13,7 +13,13 @@ const ensureOneDir = async function (path, connection) { ...@@ -13,7 +13,13 @@ const ensureOneDir = async function (path, connection) {
} }
} catch (err) { } catch (err) {
if (err.code === 'STATUS_OBJECT_NAME_NOT_FOUND') { if (err.code === 'STATUS_OBJECT_NAME_NOT_FOUND') {
await requestAsync('create_folder', {path}, connection) try {
await requestAsync('create_folder', {path}, connection)
} catch (err) {
if (err.code !== 'STATUS_OBJECT_NAME_COLLISION') {
throw err
}
}
} else { } else {
throw err throw err
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment