Fixed error in error handling :/
This commit is contained in:
parent
6a1b033f28
commit
55fb51ae0c
|
@ -30,7 +30,9 @@ FFMPEGProcessor.prototype.run = function()
|
||||||
{
|
{
|
||||||
fs.rename(tempFilename, filename, function(err)
|
fs.rename(tempFilename, filename, function(err)
|
||||||
{
|
{
|
||||||
logger.error('Could not move ' + tempFilename + ' to ' + filename + ': ' + err.message);
|
if (err)
|
||||||
|
logger.error('Could not move ' + tempFilename + ' to ' + filename + ': ' + err);
|
||||||
|
|
||||||
self.doEnd();
|
self.doEnd();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -69,7 +69,8 @@ HTTPFFMPEGProcessor.prototype.cleanup = function()
|
||||||
|
|
||||||
fs.rename(this.tempFilename, this.filename, function(err)
|
fs.rename(this.tempFilename, this.filename, function(err)
|
||||||
{
|
{
|
||||||
logger.error('Could not move ' + this.tempFilename + ' to ' + this.filename + ': ' + err.message);
|
if (err)
|
||||||
|
logger.error('Could not move ' + this.tempFilename + ' to ' + this.filename + ': ' + err);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,8 @@ HTTPRawProcessor.prototype.cleanup = function()
|
||||||
|
|
||||||
fs.rename(this.tempFilename, this.filename, function(err)
|
fs.rename(this.tempFilename, this.filename, function(err)
|
||||||
{
|
{
|
||||||
logger.error('Could not move ' + this.tempFilename + ' to ' + this.filename + ': ' + err.message);
|
if (err)
|
||||||
|
logger.error('Could not move ' + this.tempFilename + ' to ' + this.filename + ': ' + err);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue