Skip to content

Commit 7b7e91b

Browse files
author
JJ Allaire
committed
remove unnecessary async
1 parent 7f79e2a commit 7b7e91b

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

‎src/core/schema/chunk-metadata.ts‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,24 +112,24 @@ export const jupyterCellOptionsSchema = withId(
112112

113113
export const rCellOptionsSchema = withId(commonCellOptionsSchema, "r");
114114

115-
export async function getLanguageOptionsSchema(
115+
export function getLanguageOptionsSchema(
116116
normalized?: boolean,
117117
): Promise<Record<string, Schema>> {
118118
// currently this could be sync but eventually it'll be just like the
119119
// other schema, produced from YAML and hence async
120120

121121
// FIXME put this behind a cache; it's super inefficient.
122122
if (normalized) {
123-
return {
123+
return Promise.resolve({
124124
"ojs": normalizeSchema(ojsCellOptionsSchema),
125125
"python": normalizeSchema(jupyterCellOptionsSchema),
126126
"r": normalizeSchema(rCellOptionsSchema),
127-
};
127+
});
128128
} else {
129-
return {
129+
return Promise.resolve({
130130
"ojs": ojsCellOptionsSchema,
131131
"python": jupyterCellOptionsSchema,
132132
"r": rCellOptionsSchema,
133-
};
133+
});
134134
}
135135
}

0 commit comments

Comments
 (0)