Skip to content

Commit 05b2b53

Browse files
committed
Use content_by_lua_block in examples
1 parent 5b867d2 commit 05b2b53

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ server {
5656
location /simpleinterface {
5757
resolver 8.8.8.8; # use Google's open DNS server for an example
5858

59-
content_by_lua '
59+
content_by_lua_block {
6060

6161
-- For simple singleshot requests, use the URI interface.
6262
local http = require "resty.http"
@@ -87,12 +87,12 @@ server {
8787
end
8888

8989
ngx.say(res.body)
90-
';
90+
}
9191
}
9292

9393

9494
location /genericinterface {
95-
content_by_lua '
95+
content_by_lua_block {
9696

9797
local http = require "resty.http"
9898
local httpc = http.new()
@@ -134,7 +134,7 @@ server {
134134
ngx.say("failed to set keepalive: ", err)
135135
return
136136
end
137-
';
137+
}
138138
}
139139
}
140140
````

0 commit comments

Comments
 (0)