fix codex issue

Signed-off-by: bitbegin <lizhifeng23@huawei.com>
This commit is contained in:
bitbegin
2025-09-25 09:58:39 +08:00
parent 1ac4c5efb5
commit a67fcced98
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -52,7 +52,7 @@ void NapiEvent::EventNotify(AsyncEventData *asyncEvent)
napi_open_handle_scope(asyncEvent->env_, &scope);
if (scope == nullptr) {
HILOGE("scope is nullptr");
napi_close_handle_scope(asyncEvent->env_, scope);
delete asyncEvent;
return;
}
napi_value undefine;
+1 -1
View File
@@ -71,7 +71,7 @@ NfcTagClient::~NfcTagClient()
const char* NfcTagClient::GetErrCodeString(ErrCode code)
{
if ((code >= 0) && (code <= NFC_ERR_MAX)) {
for (int i = 0; i < sizeof(g_errCodeMap)/sizeof(ErrCodeMap); ++i) {
for (int i = 0; i < static_cast<int>(sizeof(g_errCodeMap)/sizeof(ErrCodeMap)); ++i) {
if (g_errCodeMap[i].code == code) {
return g_errCodeMap[i].str;
}