Skip to content

Commit 0e2bf0c

Browse files
committed
Adjustments
1 parent 33073c4 commit 0e2bf0c

File tree

6 files changed

+6
-4
lines changed

6 files changed

+6
-4
lines changed

components/webflow_v2/webflow_v2.app.mjs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export default {
2323
const sites = await this.getSites();
2424

2525
return sites.map((site) => ({
26-
label: site.name,
26+
label: site.displayName || site.shortName,
2727
value: site._id,
2828
}));
2929
},
@@ -189,7 +189,8 @@ export default {
189189
async getSites() {
190190
const webflow = this._createApiClient();
191191

192-
return await webflow.sites.list();
192+
const response = await webflow.sites.list();
193+
return response?.sites;
193194
},
194195
/**
195196
* Get a collection;
@@ -217,9 +218,10 @@ export default {
217218

218219
if (!siteId) return [];
219220

220-
return await webflow.collections.list({
221+
const response = await webflow.collections.list({
221222
siteId: siteId,
222223
});
224+
return response?.collections;
223225
},
224226
/**
225227
* Get a list of items;
@@ -240,7 +242,7 @@ export default {
240242
offset: page,
241243
});
242244

243-
return response;
245+
return response?.items;
244246
},
245247
},
246248
};

0 commit comments

Comments
 (0)