syncCollection before createCollection
This commit is contained in:
parent
06c2a0f832
commit
717b22e9c3
|
@ -224,7 +224,7 @@ export const createCollection = async (
|
||||||
type: CollectionType,
|
type: CollectionType,
|
||||||
): Promise<Collection> => {
|
): Promise<Collection> => {
|
||||||
try {
|
try {
|
||||||
const existingCollections = await getLocalCollections();
|
const existingCollections = await syncCollections();
|
||||||
for (const collection of existingCollections) {
|
for (const collection of existingCollections) {
|
||||||
if (collection.name === collectionName) {
|
if (collection.name === collectionName) {
|
||||||
return collection;
|
return collection;
|
||||||
|
|
Loading…
Reference in a new issue