Skip to content

Commit

Permalink
Little fix on code example
Browse files Browse the repository at this point in the history
PR-URL: nodejs/node-addon-api#470
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Hitesh Kanwathirtha <digitalinfinity@gmail.com>
  • Loading branch information
Marlyfleitas committed May 17, 2019
1 parent 750f7ae commit d4b7cd5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions doc/object.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ Void Init(Env env) {

// Assign values to properties
obj.Set("hello", "world");
obj.Set(42, "The Answer to Life, the Universe, and Everything");
obj.Set(uint32_t(42), "The Answer to Life, the Universe, and Everything");
obj.Set("Douglas Adams", true);

// Get properties
Value val1 = obj.Get("hello");
Value val2 = obj.Get(42);
Value val2 = obj.Get(uint32_t(42));
Value val3 = obj.Get("Douglas Adams");

// Test if objects have properties.
Expand Down

0 comments on commit d4b7cd5

Please sign in to comment.