Skip to content

🎥 Make videos programmatically with React

it needs await to use result of async function

yuta0801e50115ff4dce
diff --git a/packages/cli/src/render.tsx b/packages/cli/src/render.tsx
index 8790164bd8..cfe0e8bb36 100644
--- a/packages/cli/src/render.tsx
+++ b/packages/cli/src/render.tsx
@@ -48,7 +48,7 @@ export const render = async () => {
fileExtension: getUserPassedFileExtension(),
emitWarning: true,
});
- if (codec === 'vp8' && !ffmpegHasFeature('enable-libvpx')) {
+ if (codec === 'vp8' && !(await ffmpegHasFeature('enable-libvpx'))) {
console.log(
"The Vp8 codec has been selected, but your FFMPEG binary wasn't compiled with the --enable-lipvpx flag."
);
@@ -56,7 +56,7 @@ export const render = async () => {
'This does not work, please switch out your FFMPEG binary or choose a different codec.'
);
}
- if (codec === 'h265' && !ffmpegHasFeature('enable-gpl')) {
+ if (codec === 'h265' && !(await ffmpegHasFeature('enable-gpl'))) {
console.log(
"The H265 codec has been selected, but your FFMPEG binary wasn't compiled with the --enable-gpl flag."
);
@@ -64,7 +64,7 @@ export const render = async () => {
'This does not work, please recompile your FFMPEG binary with --enable-gpl --enable-libx265 or choose a different codec.'
);
}
- if (codec === 'h265' && !ffmpegHasFeature('enable-libx265')) {
+ if (codec === 'h265' && !(await ffmpegHasFeature('enable-libx265'))) {
console.log(
"The H265 codec has been selected, but your FFMPEG binary wasn't compiled with the --enable-libx265 flag."
);