Skip to content

Commit

Permalink
Update jsb_cocos_manual.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
dumganhar authored Jul 31, 2024
1 parent 433bc5a commit d4bfc64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions native/cocos/bindings/manual/jsb_cocos_manual.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -722,10 +722,10 @@ static bool js_readFile(se::State &s) { // NOLINT
if (!engine) {
return;
}


std::shared_ptr<std::u16string> u16str;
// TODO(cjh): OpenHarmony NAPI support
#if SCRIPT_ENGINE_TYPE != SCRIPT_ENGINE_NAPI
std::shared_ptr<std::u16string> u16str;
if constexpr (std::is_same_v<T, ccstd::string> && isJson) {
u16str = std::make_shared<std::u16string>();
if (!cc::StringUtils::UTF8ToUTF16(*content, *u16str)) {
Expand Down

0 comments on commit d4bfc64

Please sign in to comment.