update db record when we findout the disk space of an event

pull/2077/head
Isaac Connor 2017-10-10 13:02:26 -04:00
parent 9f22b3ccf4
commit 76d37d4c95
1 changed files with 1 additions and 0 deletions

View File

@ -165,6 +165,7 @@ class Event {
function DiskSpace() {
if ( null == $this{'DiskSpace'} ) {
$this{'DiskSpace'} = folder_size( $this->Path() );
dbQuery( 'UPDATE Events SET DiskSpace=? WHERE Id=?', array( $this->{'DiskSpace'}, $this->{'Id'} ) );
}
return $this{'DiskSpace'};
}