MINOR Don't fatally fail on DMSDoc->getAbsoluteSize() if doc doesn't exist on filesystem
Mainly to help with dev environments which aren't fully populated with live data
This commit is contained in:
parent
f2d81e26df
commit
c5ea1b3dbd
|
@ -654,7 +654,7 @@ class DMSDocument extends DataObject implements DMSDocumentInterface {
|
|||
* Return the size of the file associated with the document
|
||||
*/
|
||||
function getAbsoluteSize() {
|
||||
return filesize($this->getFullPath());
|
||||
return file_exists($this->getFullPath()) ? filesize($this->getFullPath()) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue