Just deleted about 400 bot accounts and a bunch of spam. To mitigate this in the future, we've enabled reCaptcha on signup. Let me know if someone got caught in the crossfire.

Commit 6235e411 authored by Intigracy's avatar Intigracy Committed by GitHub
Browse files

Revert "removing broken polls" (#13758)

parent 8b0fb6ad
......@@ -200,8 +200,7 @@ var/list/admin_verbs_rejuv = list(
/client/proc/respawn_character
)
var/list/admin_verbs_polling = list(
/client/proc/create_poll,
/client/proc/remove_broken_polls
/client/proc/create_poll
)
//verbs which can be hidden - needs work
var/list/admin_verbs_hideable = list(
......
/client/proc/remove_broken_polls()
set name = "Remove Broken Polls"
set category = "Special Verbs"
if(!check_rights(R_POLLING))
return
if(!dbcon.IsConnected())
to_chat(src, "<span class='danger'>Failed to establish database connection.</span>")
return
var/information = alert(src, "Please be aware that this may freeze up your game for a few seconds depending on how many broken polls there are. Don't do this unless neccessary, and MAKE SURE NOBODY IS IN THE PROCESS OF CURRENTLY MAKING A POLL!","READ THIS FIRST","Cancel","I Understand")
if(information == "Cancel")
return
var/DBQuery/get_broken_poll_ids = dbcon.NewQuery("SELECT id FROM erro_poll_question WHERE polltype != 'TEXT' AND id NOT IN (SELECT pollid FROM erro_poll_option)")
get_broken_poll_ids.Execute()
var/list/poll_ids = list()
while(get_broken_poll_ids.NextRow())
var/theid = get_broken_poll_ids.item[1]
poll_ids += theid
for(var/myid in poll_ids)
var/newq = "BROKEN POLL"
var/DBQuery/end_this_poll = dbcon.NewQuery("UPDATE erro_poll_question SET question = [newq], endtime = NOW() WHERE id = [myid]")
end_this_poll.Execute()
sleep(1)
\ No newline at end of file
......@@ -966,7 +966,6 @@
#include "code\modules\admin\newbanjob.dm"
#include "code\modules\admin\player_notes.dm"
#include "code\modules\admin\player_panel.dm"
#include "code\modules\admin\remove_broken_polls.dm"
#include "code\modules\admin\topic.dm"
#include "code\modules\admin\ToRban.dm"
#include "code\modules\admin\vg-web.dm"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment