This commit is contained in:
Alex Yatskov 2019-08-17 15:42:36 -07:00
parent 9ec711b780
commit 317a7a1538
2 changed files with 5 additions and 1 deletions

View File

@ -64,7 +64,7 @@ async function apiDefinitionAdd(definition, mode, context) {
);
}
if (context.screenshot) {
if (context && context.screenshot) {
await apiInjectScreenshot(
definition,
options.anki.terms.fields,

View File

@ -49,6 +49,10 @@ function apiTemplateRender(template, data, dynamic) {
return utilInvoke('templateRender', {data, template, dynamic});
}
function apiAudioGetUrl(definition, source) {
return utilInvoke('audioGetUrl', {definition, source});
}
function apiCommandExec(command) {
return utilInvoke('commandExec', {command});
}