Skip to content

Commit

Permalink
Using v8::Handle instead of v8::Local for older versions of Node
Browse files Browse the repository at this point in the history
  • Loading branch information
noonat committed Nov 11, 2015
1 parent c2e62d6 commit e24ee51
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/robotjs.cc
Original file line number Diff line number Diff line change
Expand Up @@ -433,10 +433,10 @@ int GetFlagsFromValue(v8::Handle<v8::Value> value, MMKeyFlags* flags)
// Optionally allow an array of flag strings to be passed
if (value->IsArray())
{
v8::Local<v8::Array> a = v8::Local<v8::Array>::Cast(value);
v8::Handle<v8::Array> a = v8::Handle<v8::Array>::Cast(value);
for (uint32_t i = 0; i < a->Length(); i++)
{
v8::Local<v8::Value> v(a->Get(i));
v8::Handle<v8::Value> v(a->Get(i));
if (!v->IsString()) return -2;

MMKeyFlags f = MOD_NONE;
Expand Down Expand Up @@ -505,7 +505,6 @@ NAN_METHOD(keyToggle)

bool down;
char *k;
char *f;

//Get arguments from JavaScript.
Nan::Utf8String kstr(info[0]);
Expand Down

0 comments on commit e24ee51

Please sign in to comment.