|
|
@ -671,11 +671,9 @@ export class AbstractSession extends Session { |
|
|
|
/** |
|
|
|
/** |
|
|
|
* Cancels running the session. |
|
|
|
* Cancels running the session. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
cancel() { |
|
|
|
async cancel() { |
|
|
|
const sessionId = this.getSessionId(); |
|
|
|
const sessionId = this.getSessionId(); |
|
|
|
if (sessionId === undefined) { |
|
|
|
if (sessionId !== undefined) { |
|
|
|
return FFmpegKitReactNativeModule.cancel(); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
return FFmpegKitReactNativeModule.cancelSession(sessionId); |
|
|
|
return FFmpegKitReactNativeModule.cancelSession(sessionId); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|