diff --git a/src/renderer.jsx b/src/renderer.jsx index 9075dc1b..8407bab2 100644 --- a/src/renderer.jsx +++ b/src/renderer.jsx @@ -17,7 +17,7 @@ const dialog = electron.remote.dialog; function setFileNameTitle(filePath) { const appName = 'LosslessCut'; - document.title = `${appName} - ${path.basename(filePath)}`; + document.title = filePath ? `${appName} - ${path.basename(filePath)}` : 'appName'; } function getVideo() { @@ -110,6 +110,8 @@ class App extends React.Component { resetState(); + setFileNameTitle(); + this.setState({ working: true }); return ffmpeg.getFormat(filePath)