mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-13 21:21:27 +00:00
return null if no folder was found by getParent()
This commit is contained in:
parent
247e8b09ca
commit
47e07ae2d1
|
@ -347,11 +347,12 @@ class SeedDMS_Core_Folder extends SeedDMS_Core_Object {
|
||||||
/**
|
/**
|
||||||
* Returns the parent
|
* Returns the parent
|
||||||
*
|
*
|
||||||
* @return bool|SeedDMS_Core_Folder
|
* @return null|bool|SeedDMS_Core_Folder returns null, if there is no parent folder
|
||||||
|
* and false in case of an error
|
||||||
*/
|
*/
|
||||||
public function getParent() { /* {{{ */
|
public function getParent() { /* {{{ */
|
||||||
if ($this->_id == $this->_dms->rootFolderID || empty($this->_parentID)) {
|
if ($this->_id == $this->_dms->rootFolderID || empty($this->_parentID)) {
|
||||||
return false;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!isset($this->_parent)) {
|
if (!isset($this->_parent)) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user