From 3d211facf62947336fe3c5becb0536990be8d716 Mon Sep 17 00:00:00 2001 From: tommy Date: Thu, 12 Sep 2024 12:23:49 -0400 Subject: [PATCH] doesn't really matter --- src/Modules/strafes_net.lua | 3 ++- src/SlashCommands/User.lua | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Modules/strafes_net.lua b/src/Modules/strafes_net.lua index 16470ef..8101b67 100644 --- a/src/Modules/strafes_net.lua +++ b/src/Modules/strafes_net.lua @@ -265,8 +265,9 @@ end function API:GetRobloxInfoFromUsername(USERNAME) if not USERNAME then return 'empty username' end + if #USERNAME > 32 then return 'Username too long' end local response,headers = http_request('POST', ROBLOX_API_URL..'usernames/users', API_HEADER, {usernames={USERNAME}}) - if not response.data[1] then return 'invalid username' end + if not response.data[1] then return 'Username \''..USERNAME..'\' not found.' end return self:GetRobloxInfoFromUserId(response.data[1].id) end diff --git a/src/SlashCommands/User.lua b/src/SlashCommands/User.lua index 0533487..c6904ee 100644 --- a/src/SlashCommands/User.lua +++ b/src/SlashCommands/User.lua @@ -95,7 +95,7 @@ local function Callback(Interaction, Command, Args) end end if not user_info.id then - return error('stop doing that') + return error(user_info) end local description = user_info.description=='' and 'This user has no description' or user_info.description