From 537d3bb33b58146a415e0fbbd15e1c0d1f402be7 Mon Sep 17 00:00:00 2001 From: zouheng <18179045811@163.com> Date: Fri, 29 Aug 2025 14:52:36 +0800 Subject: [PATCH] =?UTF-8?q?ani=5Frequest=5Fenable=E6=97=A5=E5=BF=97?= =?UTF-8?q?=E6=95=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zouheng <18179045811@163.com> --- .../ets/ani/src/manager/ani_request_enable.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/frameworks/ets/ani/src/manager/ani_request_enable.cpp b/frameworks/ets/ani/src/manager/ani_request_enable.cpp index 07a73ceb2..3460e8ca8 100644 --- a/frameworks/ets/ani/src/manager/ani_request_enable.cpp +++ b/frameworks/ets/ani/src/manager/ani_request_enable.cpp @@ -28,7 +28,7 @@ bool GetEnableNotificationInfo(ani_env *env, ani_object content, std::shared_ptr { ANS_LOGD("enter"); if (content == nullptr) { - ANS_LOGD("content is null"); + ANS_LOGE("content is null"); return true; } ani_status status = ANI_OK; @@ -54,12 +54,12 @@ void RequestEnableExecute(std::shared_ptr &info) ANS_LOGD("enter"); sptr client = nullptr; if (!AnsDialogHostClient::CreateIfNullptr(client)) { - ANS_LOGD("create client fail"); + ANS_LOGE("create client fail"); info->errorCode = ERR_ANS_DIALOG_IS_POPPING; return; } if (client == nullptr) { - ANS_LOGD("client is nullptr"); + ANS_LOGE("client is nullptr"); info->errorCode = ERROR_INTERNAL_ERROR; return; } @@ -95,7 +95,7 @@ void StsAsyncCompleteCallbackRequestEnableNotification(ani_env *env, std::shared ANS_LOGD("Resolve. errorCode %{public}d", errorCode); ani_object ret = OHOS::AppExecFwk::CreateInt(env, errorCode); if (ret == nullptr) { - ANS_LOGD("createInt faild"); + ANS_LOGE("createInt faild"); return; } if (ANI_OK != (status = env->PromiseResolver_Resolve(info->resolver, static_cast(ret)))) { @@ -199,13 +199,13 @@ ani_object AniRequestEnableNotification(ani_env *env, ani_object content) ANS_LOGD("enter"); std::shared_ptr info = std::make_shared(); if (!GetEnableNotificationInfo(env, content, info)) { - ANS_LOGD("GetEnableNotificationInfo"); + ANS_LOGE("GetEnableNotificationInfo"); return nullptr; } ani_object aniPromise {}; ani_resolver aniResolver {}; if (ANI_OK != env->Promise_New(&aniResolver, &aniPromise)) { - ANS_LOGD("Promise_New faild"); + ANS_LOGE("Promise_New faild"); return nullptr; } info->resolver = aniResolver; -- Gitee