Merge pull request #105 from GilgusMaximus/master
Fix for missing storyboards in dev mode
This commit is contained in:
commit
34daa0218e
|
@ -653,11 +653,14 @@ export default Vue.extend({
|
||||||
if (this.isDev) {
|
if (this.isDev) {
|
||||||
fileLocation = `storyboards/${this.videoId}.vtt`
|
fileLocation = `storyboards/${this.videoId}.vtt`
|
||||||
uriSchema = fileLocation
|
uriSchema = fileLocation
|
||||||
|
// if the location does not exist, writeFileSync will not create the directory, so we have to do that manually
|
||||||
|
if (!fs.existsSync('storyboards/')) {
|
||||||
|
fs.mkdirSync('storyboards/')
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
fileLocation = `${userData}/storyboards/${this.videoId}.vtt`
|
fileLocation = `${userData}/storyboards/${this.videoId}.vtt`
|
||||||
uriSchema = `file://${fileLocation}`
|
uriSchema = `file://${fileLocation}`
|
||||||
}
|
}
|
||||||
|
|
||||||
fs.writeFileSync(fileLocation, results)
|
fs.writeFileSync(fileLocation, results)
|
||||||
|
|
||||||
this.videoStoryboardSrc = uriSchema
|
this.videoStoryboardSrc = uriSchema
|
||||||
|
|
Loading…
Reference in New Issue