Skip to content

Commit

Permalink
refactor(base): NewV8String FromMaybe
Browse files Browse the repository at this point in the history
  • Loading branch information
spacelan committed Jun 26, 2019
1 parent 062ed88 commit 9dc7006
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion base/bundle.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@

namespace openrasp {
inline v8::Local<v8::String> NewV8String(v8::Isolate* isolate, const char* str, size_t len = -1) {
return v8::String::NewFromUtf8(isolate, str, v8::NewStringType::kNormal, len).ToLocalChecked();
return v8::String::NewFromUtf8(isolate, str, v8::NewStringType::kNormal, len).FromMaybe(v8::Local<v8::String>());
}

inline v8::Local<v8::String> NewV8String(v8::Isolate* isolate, const std::string& str) {
Expand Down

0 comments on commit 9dc7006

Please sign in to comment.