diff options
author | Michael Martin <flrgh@protonmail.com> | 2021-12-21 17:49:17 -0800 |
---|---|---|
committer | Michael Martin <flrgh@protonmail.com> | 2021-12-21 17:49:17 -0800 |
commit | 19591ff2f4a05fcadb574c0fc588325e217bd3ff (patch) | |
tree | b8d8eaadb1e5fa5de6309e410a082cdc03690167 /meta/3rd/OpenResty/library/ngx.base64.lua | |
parent | 72f6b2f920f16be027cc05bb4e189870c641817e (diff) | |
download | lua-language-server-19591ff2f4a05fcadb574c0fc588325e217bd3ff.zip |
chore: update/cleanup ngx.* modules in resty.core
Diffstat (limited to 'meta/3rd/OpenResty/library/ngx.base64.lua')
-rw-r--r-- | meta/3rd/OpenResty/library/ngx.base64.lua | 25 |
1 files changed, 20 insertions, 5 deletions
diff --git a/meta/3rd/OpenResty/library/ngx.base64.lua b/meta/3rd/OpenResty/library/ngx.base64.lua index 667e97fb..5f8184d5 100644 --- a/meta/3rd/OpenResty/library/ngx.base64.lua +++ b/meta/3rd/OpenResty/library/ngx.base64.lua @@ -1,6 +1,21 @@ ---@meta -ngx_base64={} -function ngx_base64.encode_base64url(s) end -function ngx_base64.decode_base64url(s) end -ngx_base64.version="0.1.17" -return ngx_base64
\ No newline at end of file +local base64 = { + version = require("resty.core.base").version, +} + +---Encode input using base64url rules. Returns the encoded string. +---@param s string +---@return string +function base64.encode_base64url(s) end + +---Decode input using base64url rules. Returns the decoded string. +--- +---If the input is not a valid base64url encoded string, decoded will be `nil` +---and err will be a string describing the error. +--- +---@param s string +---@return string? decoded +---@return string? err +function base64.decode_base64url(s) end + +return base64
\ No newline at end of file |