未验证 提交 d1f36fdc 编写于 作者: O openharmony_ci 提交者: Gitee

!11708 修改创建session时传入的type参数

Merge pull request !11708 from LeiiYB/master
......@@ -54,10 +54,9 @@ import featureAbility from '@ohos.ability.featureAbility';
let session;
let tag = "createNewSession";
let type = "audio";
let context = featureAbility.getContext();
await avSession.createAVSession(context, tag, type).then((avSession) => {
await avSession.createAVSession(context, tag, "audio").then((avSession) => {
session = avSession;
console.info(`CreateAVSession : SUCCESS : sessionId = ${session.sessionId}`);
}).catch((err) => {
......@@ -96,10 +95,9 @@ import featureAbility from '@ohos.ability.featureAbility';
let session;
let tag = "createNewSession";
let type = "audio";
let context = featureAbility.getContext();
avSession.createAVSession(context, tag, type, function (err, avSession) {
avSession.createAVSession(context, tag, "audio", function (err, avSession) {
if (err) {
console.info(`CreateAVSession BusinessError: code: ${err.code}, message: ${err.message}`);
} else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册