i want to make a invite friend button but it gives me a BIG warning. How do i fix it (so i dont get a warning)?

The Script :

function Invite()
local Success, result = pcall(function()
return game:GetService("SocialService"):CanSendGameInviteAsync(game.Players.LocalPlayer)
end)
	
if result == true then
game:GetService("SocialService"):PromptGameInvite(game.Players.LocalPlayer)
end
end

The First Warning :

CorePackages.AppTempCommon.LuaChat.Utils.getFriendsActiveGamesPlaceIdsFromUsersPresence:13: attempt to index nil with '115797356' 

The Second Warning :

CorePackages.AppTempCommon.LuaChat.Utils.getFriendsActiveGamesPlaceIdsFromUsersPresence:13: attempt to index nil with '719754874'

CorePackages.Packages._Index.lua-promise.lua-promise:82 function new
CorePackages.Packages._Index.lua-promise.lua-promise:222 function andThen
CoreGui.RobloxGui.Modules.Settings.Pages.ShareGame.Thunks.ApiFetchUsersFriends:28
CorePackages.Packages._Index.roblox_rodux.rodux.thunkMiddleware:10
CorePackages.Packages._Index.roblox_rodux.rodux.Store:62
CoreGui.RobloxGui.Modules.Settings.Pages.ShareGame.Thunks.FetchUserFriends:19
CorePackages.Packages._Index.roblox_rodux.rodux.thunkMiddleware:10
CorePackages.Packages._Index.roblox_rodux.rodux.Store:62
CorePackages.Packages._Index.roblox_roact-rodux.roact-rodux.connect:149
CoreGui.RobloxGui.Modules.Settings.Pages.ShareGame.Components.ShareGameContainer:55
CoreGui.RobloxGui.Modules.Settings.Pages.ShareGame.Components.ShareGameContainer:30 function init
CorePackages.Packages._Index.roblox_roact.roact.Component:323 function __mount
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:363 function mountVirtualNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:93 function updateChildren
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:119 function updateVirtualNodeWithRenderResult
CorePackages.Packages._Index.roblox_roact.roact.Component:334 function __mount
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:363 function mountVirtualNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:93 function updateChildren
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:119 function updateVirtualNodeWithRenderResult
CorePackages.Packages._Index.roblox_roact.roact.Component:334 function __mount
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:363 function mountVirtualNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:93 function updateChildren
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:119 function updateVirtualNodeWithRenderResult
CorePackages.Packages._Index.roblox_roact.roact.Component:334 function __mount
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:363 function mountVirtualNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:93 function updateChildren
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:111 function updateVirtualNodeWithChildren
CorePackages.Packages._Index.roblox_roact.roact.RobloxRenderer:215 function mountHostNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:359 function mountVirtualNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:93 function updateChildren
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:119 function updateVirtualNodeWithRenderResult
CorePackages.Packages._Index.roblox_roact.roact.Component:334 function __mount
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:363 function mountVirtualNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:93 function updateChildren
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:119 function updateVirtualNodeWithRenderResult
CorePackages.Packages._Index.roblox_roact.roact.Component:334 function __mount
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:363 function mountVirtualNode
CorePackages.Packages._Index.roblox_roact.roact.createReconciler:399 function mountVirtualTree
CoreGui.RobloxGui.Modules.Settings.Pages.ShareGame.InviteToGamePrompt:71 function show
CoreGui.RobloxGui.CoreScripts/InviteToGamePrompt:33

1 comment

0

that seems like a roblox core error, maybe some core bug that has not yet been fixed.