Empty commit

This commit is contained in:
Git 2012-12-26 08:00:54 +00:00
parent 5c2dee6000
commit f0126d3d47
4 changed files with 17 additions and 10 deletions

View File

@ -423,6 +423,12 @@ CREATE TABLE `ip_bans` (
KEY `ToIP` (`ToIP`) KEY `ToIP` (`ToIP`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1; ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
CREATE TABLE `lastfm_users` (
`ID` int(10) unsigned NOT NULL,
`Username` varchar(20) NOT NULL,
PRIMARY KEY (`ID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
CREATE TABLE `library_contest` ( CREATE TABLE `library_contest` (
`UserID` int(10) NOT NULL, `UserID` int(10) NOT NULL,
`TorrentID` int(10) NOT NULL, `TorrentID` int(10) NOT NULL,

View File

@ -307,7 +307,7 @@ function next_hour() {
$Message = 'You have downloaded more then 10 GiB while on Ratio Watch. Your leeching privileges have been disabled. Please reread the rules and refer to this guide on how to improve your ratio https://what.cd/wiki.php?action=article&id=110'; $Message = 'You have downloaded more then 10 GiB while on Ratio Watch. Your leeching privileges have been disabled. Please reread the rules and refer to this guide on how to improve your ratio https://what.cd/wiki.php?action=article&id=110';
foreach($UserIDs as $UserID) { foreach($UserIDs as $UserID) {
Misc::send_pm($UserID,0,db_string($Subject),db_string($Message)); Misc::send_pm($UserID,0,db_string($Subject),db_string($Message));
send_irc("PRIVMSG #reports : !leechdisabled Downloaded 10 GB+ on Ratio Watch. https://".NONSSL_SITE_URL."/user.php?id=$UserID"); send_irc("PRIVMSG #reports : !leechdisabled Downloaded 10 GB+ on Ratio Watch. https://what.cd/user.php?id=$UserID");
} }
$DB->query("UPDATE users_info AS i JOIN users_main AS m ON m.ID=i.UserID $DB->query("UPDATE users_info AS i JOIN users_main AS m ON m.ID=i.UserID
@ -462,7 +462,7 @@ function next_hour() {
Tracker::update_tracker('update_user', array('passkey' => $Passkey, 'can_leech' => '1')); Tracker::update_tracker('update_user', array('passkey' => $Passkey, 'can_leech' => '1'));
} }
/*
// Put user on ratio watch if he doesn't meet the standards // Put user on ratio watch if he doesn't meet the standards
sleep(10); sleep(10);
$DB->query("SELECT m.ID, m.Downloaded FROM users_info AS i JOIN users_main AS m ON m.ID=i.UserID $DB->query("SELECT m.ID, m.Downloaded FROM users_info AS i JOIN users_main AS m ON m.ID=i.UserID
@ -487,7 +487,7 @@ function next_hour() {
Misc::send_pm($UserID, 0, db_string("You have been put on Ratio Watch"), db_string("This happens when your ratio falls below the requirements we have outlined in the rules located [url=http://".NONSSL_SITE_URL."/rules.php?p=ratio]here[/url].\n For information about ratio watch, click the link above."), ''); Misc::send_pm($UserID, 0, db_string("You have been put on Ratio Watch"), db_string("This happens when your ratio falls below the requirements we have outlined in the rules located [url=http://".NONSSL_SITE_URL."/rules.php?p=ratio]here[/url].\n For information about ratio watch, click the link above."), '');
echo "Ratio watch on: $UserID\n"; echo "Ratio watch on: $UserID\n";
} }
*/
sleep(5); sleep(5);
//------------- Rescore 0.95 logs of disabled users //------------- Rescore 0.95 logs of disabled users
@ -504,7 +504,7 @@ function next_hour() {
sleep(5); sleep(5);
//------------- Disable downloading ability of users on ratio watch //------------- Disable downloading ability of users on ratio watch
/*
$UserQuery = $DB->query("SELECT ID, torrent_pass FROM users_info AS i JOIN users_main AS m ON m.ID=i.UserID $UserQuery = $DB->query("SELECT ID, torrent_pass FROM users_info AS i JOIN users_main AS m ON m.ID=i.UserID
WHERE i.RatioWatchEnds!='0000-00-00 00:00:00' WHERE i.RatioWatchEnds!='0000-00-00 00:00:00'
@ -539,6 +539,7 @@ function next_hour() {
foreach($Passkeys as $Passkey) { foreach($Passkeys as $Passkey) {
Tracker::update_tracker('update_user', array('passkey' => $Passkey, 'can_leech' => '0')); Tracker::update_tracker('update_user', array('passkey' => $Passkey, 'can_leech' => '0'));
} }
*/
//------------- Disable inactive user accounts --------------------------// //------------- Disable inactive user accounts --------------------------//
sleep(5); sleep(5);
@ -935,11 +936,11 @@ function next_hour() {
Misc::send_pm($UserID, 0, db_string('Unseeded torrent notification'), db_string($MessageInfo['Count']." of your uploads will be deleted for inactivity soon. Unseeded torrents are deleted after 4 weeks. If you still have the files, you can seed your uploads by ensuring the torrents are in your client and that they aren't stopped. You can view the time that a torrent has been unseeded by clicking on the torrent description line and looking for the \"Last active\" time. For more information, please go [url=https://what.cd/wiki.php?action=article&id=663]here[/url].\n\nThe following torrent".($MessageInfo['Count']>1?'s':'')." will be removed for inactivity:".$MessageInfo['Msg']."\n\nIf you no longer wish to receive these notifications, please disable them in your profile settings.")); Misc::send_pm($UserID, 0, db_string('Unseeded torrent notification'), db_string($MessageInfo['Count']." of your uploads will be deleted for inactivity soon. Unseeded torrents are deleted after 4 weeks. If you still have the files, you can seed your uploads by ensuring the torrents are in your client and that they aren't stopped. You can view the time that a torrent has been unseeded by clicking on the torrent description line and looking for the \"Last active\" time. For more information, please go [url=https://what.cd/wiki.php?action=article&id=663]here[/url].\n\nThe following torrent".($MessageInfo['Count']>1?'s':'')." will be removed for inactivity:".$MessageInfo['Msg']."\n\nIf you no longer wish to receive these notifications, please disable them in your profile settings."));
} }
} }
$DB->query("UPDATE staff_pm_conversations $DB->query("UPDATE staff_pm_conversations
SET Status = 'Resolved', ResolverID = '0' SET Status = 'Resolved', ResolverID = '0'
WHERE Date < NOW() - INTERVAL 1 MONTH AND Status = 'Open' AND AssignedToUser IS NULL"); WHERE Date < NOW() - INTERVAL 1 MONTH AND Status = 'Open' AND AssignedToUser IS NULL");
} }
/*************************************************************************\ /*************************************************************************\
//--------------Run twice per month -------------------------------------// //--------------Run twice per month -------------------------------------//

View File

@ -425,7 +425,7 @@ function header_link($SortKey,$DefaultWay="desc") {
} }
} }
if (!empty($_GET['freetorrent'])) { if (!empty($_GET['freetorrent']) || $_GET['freetorrent'] === '0') {
switch ($_GET['freetorrent']) { switch ($_GET['freetorrent']) {
case 0: // Only normal freeleech case 0: // Only normal freeleech
$SphQL->where('freetorrent', 0); $SphQL->where('freetorrent', 0);

View File

@ -630,8 +630,8 @@
} }
// Use this section to control freeleeches // Use this section to control freeleeches
$T['FreeLeech'] = 1; $T['FreeLeech'] = 0;
$T['FreeLeechType'] = 1; $T['FreeLeechType'] = 0;
// Torrent // Torrent
$DB->query(" $DB->query("