Permalink
Browse files

Don't use SetMethod()

  • Loading branch information...
1 parent 3770274 commit 030b48e633714b1585879d53fa7d6a4be4e827de @jmendeth jmendeth committed Sep 13, 2012
Showing with 15 additions and 15 deletions.
  1. +15 −15 src/robotskirt.cc
View
@@ -1040,21 +1040,21 @@ namespace houdini {
//The initializer
NODE_DEF(init) {
- SetMethod(target, "escapeJS", EscapeJs);
- SetMethod(target, "unescapeJS", UnescapeJs);
-
- SetMethod(target, "escapeURL", EscapeUrl);
- SetMethod(target, "unescapeURL", UnescapeUrl);
-
- SetMethod(target, "escapeURI", EscapeUri);
- SetMethod(target, "unescapeURI", UnescapeUri);
-
- SetMethod(target, "escapeHTML", EscapeHtml);
- SetMethod(target, "unescapeHTML", UnescapeHtml);
-
- SetMethod(target, "escapeHREF", EscapeHref);
-
- SetMethod(target, "escapeXML", EscapeXml);
+ target->Set(Symbol("escapeJS"), Func(EscapeJs)->GetFunction());
+ target->Set(Symbol("unescapeJS"), Func(UnescapeJs)->GetFunction());
+
+ target->Set(Symbol("escapeURL"), Func(EscapeUrl)->GetFunction());
+ target->Set(Symbol("unescapeURL"), Func(UnescapeUrl)->GetFunction());
+
+ target->Set(Symbol("escapeURI"), Func(EscapeUri)->GetFunction());
+ target->Set(Symbol("unescapeURI"), Func(UnescapeUri)->GetFunction());
+
+ target->Set(Symbol("escapeHTML"), Func(EscapeHtml)->GetFunction());
+ target->Set(Symbol("unescapeHTML"), Func(UnescapeHtml)->GetFunction());
+
+ target->Set(Symbol("escapeHREF"), Func(EscapeHref)->GetFunction());
+
+ target->Set(Symbol("escapeXML"), Func(EscapeXml)->GetFunction());
}
};

0 comments on commit 030b48e

Please sign in to comment.