Simplified fetchLabels to return an array of label names (#16842)

refs https://github.com/TryGhost/Team/issues/3182
This commit is contained in:
Sag 2023-05-23 08:48:14 +02:00 committed by GitHub
parent 1139ed541b
commit 2526bd627e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -252,12 +252,7 @@ export default class KoenigLexicalEditor extends Component {
const fetchLabels = async () => {
const labels = await this.fetchLabelsTask.perform();
return labels.toArray().map((label) => {
return {
id: label.id,
name: label.name
};
});
return labels.map(label => label.name);
};
const defaultCardConfig = {