mirror of
https://git.phreedom.club/localhost_frssoft/fediauth.git
synced 2025-01-07 00:24:32 +00:00
micro fixes
This commit is contained in:
parent
6b95a65a08
commit
fd62b10c9c
4
join.lua
4
join.lua
|
@ -129,14 +129,14 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
|
|||
minetest.show_formspec(playername, FORMNAMEFEDI, formspecfediadd)
|
||||
return
|
||||
end
|
||||
fedihandle = fields.fediverse_account_url:split("@")
|
||||
local fedihandle = fields.fediverse_account_url:split("@")
|
||||
if #fedihandle ~= 2 then
|
||||
minetest.chat_send_player(playername, minetest.colorize("#ff0000", "Incorrect format"))
|
||||
minetest.show_formspec(playername, FORMNAMEFEDI, formspecfediadd)
|
||||
return
|
||||
end
|
||||
if fediauth.check_for_restricted_instance(fedihandle[2]) then
|
||||
minetest.chat_send_player(playername, minetest.colorize("#ff0000", fedihandle[2] .. "has restricted, try another..."))
|
||||
minetest.chat_send_player(playername, minetest.colorize("#ff0000", fedihandle[2] .. " has restricted, try another..."))
|
||||
minetest.show_formspec(playername, FORMNAMEFEDI, formspecfediadd)
|
||||
return
|
||||
end
|
||||
|
|
|
@ -46,13 +46,13 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
|
|||
minetest.chat_send_player(playername, minetest.colorize("#ff0000", "Try again, your input is incorrect"))
|
||||
return
|
||||
end
|
||||
fedihandle = fields.fediverse_account_url:split("@")
|
||||
local fedihandle = fields.fediverse_account_url:split("@")
|
||||
if #fedihandle ~= 2 then
|
||||
minetest.chat_send_player(playername, minetest.colorize("#ff0000", "Incorrect format"))
|
||||
return
|
||||
end
|
||||
if fediauth.check_for_restricted_instance(fedihandle[2]) then
|
||||
minetest.chat_send_player(playername, minetest.colorize("#ff0000", fedihandle[2] .. "has restricted, try another..."))
|
||||
minetest.chat_send_player(playername, minetest.colorize("#ff0000", fedihandle[2] .. " has restricted, try another..."))
|
||||
return
|
||||
end
|
||||
local secret_b32 = fediauth.get_player_secret_b32(playername)
|
||||
|
|
Loading…
Reference in a new issue