changeset 3011:55d49eb065ac

Fixed example in the js_periodic directive.
author Yaroslav Zhuravlev <yar@nginx.com>
date Thu, 14 Sep 2023 16:38:00 +0100
parents 758e2e1dfd22
children ac4191d05fdf
files xml/en/docs/http/ngx_http_js_module.xml xml/en/docs/stream/ngx_stream_js_module.xml xml/ru/docs/http/ngx_http_js_module.xml xml/ru/docs/stream/ngx_stream_js_module.xml
diffstat 4 files changed, 12 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/xml/en/docs/http/ngx_http_js_module.xml
+++ b/xml/en/docs/http/ngx_http_js_module.xml
@@ -9,7 +9,7 @@
 <module name="Module ngx_http_js_module"
         link="/en/docs/http/ngx_http_js_module.html"
         lang="en"
-        rev="42">
+        rev="43">
 
 <section id="summary">
 
@@ -602,8 +602,8 @@ location @periodics {
 example.js:
 
 async function handler(s) {
-    let reply = async ngx.fetch('https://nginx.org/en/docs/njs/');
-    let body = async reply.text();
+    let reply = await ngx.fetch('https://nginx.org/en/docs/njs/');
+    let body = await reply.text();
 
     ngx.log(ngx.INFO, body);
 }
--- a/xml/en/docs/stream/ngx_stream_js_module.xml
+++ b/xml/en/docs/stream/ngx_stream_js_module.xml
@@ -9,7 +9,7 @@
 <module name="Module ngx_stream_js_module"
         link="/en/docs/stream/ngx_stream_js_module.html"
         lang="en"
-        rev="41">
+        rev="42">
 
 <section id="summary">
 
@@ -519,8 +519,8 @@ location @periodics {
 example.js:
 
 async function handler(s) {
-    let reply = async ngx.fetch('https://nginx.org/en/docs/njs/');
-    let body = async reply.text();
+    let reply = await ngx.fetch('https://nginx.org/en/docs/njs/');
+    let body = await reply.text();
 
     ngx.log(ngx.INFO, body);
 }
--- a/xml/ru/docs/http/ngx_http_js_module.xml
+++ b/xml/ru/docs/http/ngx_http_js_module.xml
@@ -9,7 +9,7 @@
 <module name="Модуль ngx_http_js_module"
         link="/ru/docs/http/ngx_http_js_module.html"
         lang="ru"
-        rev="42">
+        rev="43">
 
 <section id="summary">
 
@@ -605,8 +605,8 @@ location @periodics {
 example.js:
 
 async function handler(s) {
-    let reply = async ngx.fetch('https://nginx.org/en/docs/njs/');
-    let body = async reply.text();
+    let reply = await ngx.fetch('https://nginx.org/en/docs/njs/');
+    let body = await reply.text();
 
     ngx.log(ngx.INFO, body);
 }
--- a/xml/ru/docs/stream/ngx_stream_js_module.xml
+++ b/xml/ru/docs/stream/ngx_stream_js_module.xml
@@ -9,7 +9,7 @@
 <module name="Модуль ngx_stream_js_module"
         link="/ru/docs/stream/ngx_stream_js_module.html"
         lang="ru"
-        rev="40">
+        rev="42">
 
 <section id="summary">
 
@@ -618,8 +618,8 @@ location @periodics {
 example.js:
 
 async function handler(s) {
-    let reply = async ngx.fetch('https://nginx.org/en/docs/njs/');
-    let body = async reply.text();
+    let reply = await ngx.fetch('https://nginx.org/en/docs/njs/');
+    let body = await reply.text();
 
     ngx.log(ngx.INFO, body);
 }