Fix PHP warning from odfeditor plugin when using assets_dir

This commit is contained in:
Aleksander Machniak 2016-05-18 07:58:25 -04:00
parent 91a7cbfc40
commit 78ced412de

View file

@ -97,9 +97,9 @@ class odfviewer extends rcube_plugin
$rcmail = rcube::get_instance();
$assets_dir = $rcmail->config->get('assets_dir');
$mtime = filemtime($this->home . '/' . $path);
$mtime = @filemtime($this->home . '/' . $path);
if (!$mtime && $assets_dir) {
$mtime = filemtime($assets_dir . '/plugins/odfviewer/' . $path);
$mtime = @filemtime($assets_dir . '/plugins/odfviewer/' . $path);
}
$path = $this->urlbase . $path . ($mtime ? '?s=' . $mtime : '');