From c562d0f9e336251f9ff599a840310835820b0461 Mon Sep 17 00:00:00 2001 From: ame Date: Wed, 8 May 2024 10:55:05 -0500 Subject: work on threads --- docs/net.md | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'docs/net.md') diff --git a/docs/net.md b/docs/net.md index 28a7070..474cdbe 100644 --- a/docs/net.md +++ b/docs/net.md @@ -10,15 +10,6 @@ the function will be ran on initilization, the argument has info on the server a ** right now everything within a server:GET function is partially global, it can read global variables (by making a copy), it can not read/copy local variables or modify globals - -also, (for now) all globals must be refrenced as _G, -ie: -function foo() - ... -end - -_G.foo() -_G.llib.crypto.md5("hewwo purr") ** ```lua @@ -53,14 +44,14 @@ the second (req) contains info on the request, the path allows for wildcards, mu the actual name of the function will change based on what request method you want to accept, all requests are treated the exact same on the backend, besides HEAD requests which will also use all GET requets, and the 'all' variant will get everything ```lua -server:all("*", function(res, req, next) +server:all("*", function(res, req) if(req['Version'] ~= "HTTP/1.1") then res:close() end end) ... -server:GET("/", function(res, req) do +server:GET("/", function(res, req) --version will always be 1.1, as per the middleware ... end) -- cgit v1.2.3