mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-09-01 10:48:53 +00:00
Changes and fixes in Info.php and nzbcontents.php.
This commit is contained in:
+2
-5
@@ -485,21 +485,18 @@ Class Sharing
|
||||
if (!isset($body['USER']) || !isset($body['SID']) || !isset($body['RID']) || !isset($body['TIME']) | !isset($body['BODY'])) {
|
||||
return false;
|
||||
}
|
||||
// Hash a unique Comment ID to associate with this message
|
||||
$cid = md5($body['SID'] . $body['USER'] . $body['TIME'] . $body['BODY']);
|
||||
|
||||
// Insert the comment.
|
||||
if ($this->db->exec(
|
||||
sprintf('
|
||||
INSERT INTO releasecomment
|
||||
(text, createddate, issynced, shareID, gid, nzb_guid, cid, siteID, username, userID, releaseID, shared, host, sourceID)
|
||||
VALUES (%s, %s, 1, %s, %s, %s, %s, %s, %s, 0, 0, 2, "", 999)',
|
||||
(text, createddate, issynced, shareID, gid, nzb_guid, siteID, username, userID, releaseID, shared, host, sourceID)
|
||||
VALUES (%s, %s, 1, %s, %s, %s, %s, %s, 0, 0, 2, "", 999)',
|
||||
$this->db->escapeString($body['BODY']),
|
||||
$this->functions->from_unixtime(($body['TIME'] > time() ? time() : $body['TIME'])),
|
||||
$this->db->escapeString($body['SID']),
|
||||
$this->db->escapeString($body['RID']),
|
||||
$this->db->escapeString($body['RID']),
|
||||
$this->db->escapeString($cid),
|
||||
$this->db->escapeString($siteID),
|
||||
$this->db->escapeString((substr($body['USER'], 0, 3) === 'sn-' ? 'SH_ANON' : 'SH_' . $body['USER']))
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user