Continue to support non-USE_DEEP_STORAGE option

This commit is contained in:
Isaac Connor 2017-05-22 21:21:49 -04:00
parent 54c9c37b21
commit 75dc774a08
1 changed files with 5 additions and 2 deletions

View File

@ -94,7 +94,10 @@ class ImageComponent extends Component {
// Take the StartTime of an Event and return
// the path to its location on the filesystem
public function getEventPath( $event ) {
return $event['Event']['MonitorId'].'/'.strftime( "%y/%m/%d/%H/%M/%S", strtotime($event['Event']['StartTime']) );
}
if ( $config['ZM_USE_DEEP_STORAGE'] == 1 )
return $event['Event']['MonitorId'].'/'.strftime( "%y/%m/%d/%H/%M/%S", strtotime($event['Event']['StartTime']) );
else
return $event['Event']['MonitorId'].'/'.$event['Event']['Id'];
}
}
?>