Hello! I’m having trouble with getting the player’s UserId…It seems like it won’t pass whenever I change the card’s name in Trello to UserId. Although it works when I change the script to Player.Name and the Trello card’s name to the players user. I’d appreciate the help. Thank you!
local JanitorBlocker = game.workspace:WaitForChild("JanitorBlocker") -- this is the part that blocks the player from the janitor area
local RE = game:GetService("ReplicatedStorage"):WaitForChild("JanitorRoomClient")
JanitorBlocker.CanCollide = true
local TrelloEvent = game.ReplicatedStorage:WaitForChild("TrelloEvent")
local TrelloAPI = require(game.ServerScriptService:WaitForChild("TrelloAPI"))
local BoardID = TrelloAPI.BoardsAPI.GetBoardID("Sector Leads")
local ListId = TrelloAPI.BoardsAPI.GetListID(BoardID,"🧹 Dirty Janitors")
game.Players.PlayerAdded:Connect(function(Player)
for _, JanitorNames in pairs(TrelloAPI.CardsAPI.GetCardsOnList(ListId)) do
if JanitorNames.name == Player.UserId then
RE:FireClient(Player)
end
end
end)