mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-11 04:52:14 +09:00
Allow admin to report (declare) even if it's the same IP
This commit is contained in:
parent
e8e6546067
commit
6b956d2e5b
2 changed files with 2 additions and 2 deletions
|
|
@ -1591,7 +1591,7 @@ class commentController extends comment
|
||||||
$oComment = CommentModel::getComment($comment_srl, FALSE, FALSE);
|
$oComment = CommentModel::getComment($comment_srl, FALSE, FALSE);
|
||||||
|
|
||||||
// failed if both ip addresses between author's and the current user are same.
|
// failed if both ip addresses between author's and the current user are same.
|
||||||
if($oComment->get('ipaddress') == \RX_CLIENT_IP)
|
if($oComment->get('ipaddress') == \RX_CLIENT_IP && !$this->user->isAdmin())
|
||||||
{
|
{
|
||||||
$_SESSION['declared_comment'][$comment_srl] = TRUE;
|
$_SESSION['declared_comment'][$comment_srl] = TRUE;
|
||||||
return new BaseObject(-1, 'failed_declared');
|
return new BaseObject(-1, 'failed_declared');
|
||||||
|
|
|
||||||
|
|
@ -1690,7 +1690,7 @@ class documentController extends document
|
||||||
$oDocument = DocumentModel::getDocument($document_srl, false, false);
|
$oDocument = DocumentModel::getDocument($document_srl, false, false);
|
||||||
|
|
||||||
// Pass if the author's IP address is as same as visitor's.
|
// Pass if the author's IP address is as same as visitor's.
|
||||||
if($oDocument->get('ipaddress') == \RX_CLIENT_IP)
|
if($oDocument->get('ipaddress') == \RX_CLIENT_IP && !$this->user->isAdmin())
|
||||||
{
|
{
|
||||||
$_SESSION['declared_document'][$document_srl] = false;
|
$_SESSION['declared_document'][$document_srl] = false;
|
||||||
return new BaseObject(-1, 'failed_declared');
|
return new BaseObject(-1, 'failed_declared');
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue