# HG changeset patch # User Vladimir Homutov # Date 1599828371 -10800 # Node ID fca42223b9fc18693bbe9e9d64c37d0d7c3c243f # Parent f27cedd43e0f92266c52596487080d143ef11c92 Fixed example in the "Using node modules with njs" article. diff --git a/xml/en/docs/njs/node_modules.xml b/xml/en/docs/njs/node_modules.xml --- a/xml/en/docs/njs/node_modules.xml +++ b/xml/en/docs/njs/node_modules.xml @@ -9,7 +9,7 @@
+ rev="5">
@@ -498,7 +498,7 @@ The result is in the "dist Let's call our code at the end of a file: -var b = setbuf(1); +var b = set_buffer(global.dns); console.log(b); And execute it using node: diff --git a/xml/ru/docs/njs/node_modules.xml b/xml/ru/docs/njs/node_modules.xml --- a/xml/ru/docs/njs/node_modules.xml +++ b/xml/ru/docs/njs/node_modules.xml @@ -9,7 +9,7 @@
+ rev="5">
@@ -501,7 +501,7 @@ function set_buffer(dnsPacket) Далее осуществляется вызов кода в конце файла: -var b = setbuf(1); +var b = set_buffer(global.dns); console.log(b); И затем выполнение кода при помощи node: