Skip to content

Commit

Permalink
Merge pull request #4024 from nicoletta-maia/develop-issue_migrate_em…
Browse files Browse the repository at this point in the history
…pty_file

Issue: manage.php file migrate fails when files have size=0
  • Loading branch information
protich committed Jul 26, 2019
2 parents 889684b + 758a982 commit f8fd20f
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions include/class.error.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,15 @@ function __construct($message) {
global $ost;

parent::__construct(__($message));
$message = str_replace(ROOT_DIR, '(root)/', _S($message));

if ($ost && $ost->getConfig()->getLogLevel() == 3)
$message .= "\n\n" . $this->getBacktrace();
if ($ost) {
$message = str_replace(ROOT_DIR, '(root)/', _S($message));

$ost->logError($this->getTitle(), $message, static::$sendAlert);
if ($ost->getConfig()->getLogLevel() == 3)
$message .= "\n\n" . $this->getBacktrace();

$ost->logError($this->getTitle(), $message, static::$sendAlert);
}
}

function getTitle() {
Expand Down

0 comments on commit f8fd20f

Please sign in to comment.