mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-04 01:01:41 +09:00
Fix #1827 unnecessary use of $is_admin when getting document or comment
This commit is contained in:
parent
42442aeef7
commit
97f28141ae
3 changed files with 10 additions and 10 deletions
|
|
@ -29,7 +29,7 @@ class documentView extends document
|
|||
$document_srl = Context::get('document_srl');
|
||||
|
||||
// Creates an object for displaying the selected document
|
||||
$oDocument = DocumentModel::getDocument($document_srl, $this->grant->manager);
|
||||
$oDocument = DocumentModel::getDocument($document_srl);
|
||||
if(!$oDocument->isExists()) throw new Rhymix\Framework\Exceptions\TargetNotFound;
|
||||
// Check permissions
|
||||
if(!$oDocument->isAccessible()) throw new Rhymix\Framework\Exceptions\NotPermitted;
|
||||
|
|
@ -232,7 +232,7 @@ class documentView extends document
|
|||
}
|
||||
|
||||
// Creates an object for displaying the selected document
|
||||
$oDocument = DocumentModel::getDocument($document_srl, $this->grant->manager, FALSE);
|
||||
$oDocument = DocumentModel::getDocument($document_srl, false, false);
|
||||
if(!$oDocument->isExists())
|
||||
{
|
||||
throw new Rhymix\Framework\Exceptions\TargetNotFound;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue