I would convert whatever the user said as a command to lowercase in order to not have the command be case sensitive.
elseif SplitCommand[1]:lower() == ":unban" then
local TargetedPlayer = SplitCommand[2]
--Make sure a user with the inputted username exists via checking for a userId.
local success, result = pcall(game.Players.GetUserIdFromNameAsync, game.Players, TargetedPlayer)
if success then
Ban:SetAsync(result, false)
end