mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 02:31:40 +09:00
#211 요청받은 mid와 document_srl의 mid를 체크, 다를 경우 오류 출력
This commit is contained in:
parent
1419a09275
commit
0918ae8b7b
1 changed files with 6 additions and 3 deletions
|
|
@ -141,8 +141,9 @@ class ModuleHandler extends Handler
|
|||
}
|
||||
|
||||
// Get module's information based on document_srl, if it's specified
|
||||
if($this->document_srl && !$this->module)
|
||||
if($this->document_srl)
|
||||
{
|
||||
|
||||
$module_info = $oModuleModel->getModuleInfoByDocumentSrl($this->document_srl);
|
||||
|
||||
// If the document does not exist, remove document_srl
|
||||
|
|
@ -162,10 +163,12 @@ class ModuleHandler extends Handler
|
|||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
// if requested module is different from one of the document, remove the module information retrieved based on the document number
|
||||
if($this->module && $module_info->module != $this->module)
|
||||
{
|
||||
unset($module_info);
|
||||
$this->error = 'msg_invalid_request';
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -279,7 +282,7 @@ class ModuleHandler extends Handler
|
|||
if(!$output->toBool())
|
||||
{
|
||||
$this->error = $output->getMessage();
|
||||
return FALSE;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
// Set current module info into context
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue