Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lint Lua with luacheck #232

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from
Open

Lint Lua with luacheck #232

wants to merge 2 commits into from

Conversation

Salamandar
Copy link

  • to be verified, i don't really know lua
  • not sure all that is relevant
  • my IDE was giving me more errors than luacheck (deprecated stuff, "need to check nil", etc)

@Salamandar Salamandar changed the base branch from dev to bookworm October 24, 2024 15:32
Comment on lines -76 to +77
local header, err = cjson_safe.decode(basexx.from_url64(segments[1]))
if err then
return nil, nil, nil, "Invalid header"
end

local body, err = cjson_safe.decode(basexx.from_url64(segments[2]))
if err then
return nil, nil, nil, "Invalid body"
end

local sig, err = basexx.from_url64(segments[3])
if err then
return nil, nil, nil, "Invalid signature"
end

return header, body, sig
local segments = split_token(token)
if #segments ~= 3 then
return nil, nil, nil, "Invalid token"
end
local err, header, body, sig

header, err = cjson_safe.decode(basexx.from_url64(segments[1]))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is gonna be confusing if we ever update this vendor lib because we're not the author of this ...

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah !

Base automatically changed from bookworm to dev October 31, 2024 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants