hi guys, the map doesn't restart, and i'm testing it on the default race, any help? 
playerVotes = {} 
  
local i = 0 addCommandHandler( "vr", function(source) 
    if(playerVotes[source] == true) then return outputChatBox("#ff8800[REDO]: #ffffffYou have already voted", getRootElement(), 255,0,0, true, source) end 
    if not i then i = 0 end 
    if i >= 4 then 
        outputChatBox("", getRootElement(), 255,0,0, true) 
        outputChatBox("#ff8800[REDO]: #ffffffThe map will be restarted!", getRootElement(), 255,0,0, true) 
    else 
        playerVotes[source] = true 
        i = i + 1 
    end 
    if i == 3 then 
        outputChatBox("", getRootElement(), 255,0,0, true) 
        outputChatBox("#ff8800[REDO]: "..getPlayerName(source).."#ffffff voted for redo! ["..i.."/3]", getRootElement(), 255,0,0, true) 
        outputChatBox("", getRootElement(), 255,0,0, true) 
        outputChatBox("#ff8800[REDO]: #ffffffThis map will be restarted by vote!", getRootElement(), 255,0,0, true) 
        g_ForcedNextMap = currentMap 
        setTimer(function() i = 0 end, 150*1000,1) 
        playerVotes = {3} 
    elseif i <= 2 then 
        outputChatBox("", getRootElement(), 255,0,0, true) 
        outputChatBox("#ff8800[REDO]: "..getPlayerName(source).." #ffffffvoted for redo! ["..i.."/3]", getRootElement(), 255,0,0, true) 
    end 
end)