summaryrefslogtreecommitdiff
path: root/app/relay/modules
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2018-06-05 16:16:24 +0200
committerJules Laplace <julescarbon@gmail.com>2018-06-05 16:16:24 +0200
commitb0d534d174def2940287745535726c7e878dcbcc (patch)
tree499f8980f2e29bd36833bb943eacd01e9815759e /app/relay/modules
parente243e4f65cc2c98724a1cfb4d28ac5f1d1bc0a79 (diff)
more sane file naming
Diffstat (limited to 'app/relay/modules')
-rw-r--r--app/relay/modules/samplernn.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/app/relay/modules/samplernn.js b/app/relay/modules/samplernn.js
index 2dacaa7..73d0a5f 100644
--- a/app/relay/modules/samplernn.js
+++ b/app/relay/modules/samplernn.js
@@ -13,10 +13,11 @@ const fetch = {
listen: (task, line, i) => {
// here i need to bridge again... get the filename that comes back from youtube-dl
// and tell the cortex that URL -> fn and add the filename!
- if ( line.match(/^got fn, /) ) {
- let dataset = line.split(' => ')[1].trim()
- task.dataset = dataset
- return { type: 'progress', action: 'set_dataset', task, }
+ if ( line.match(/^youtube-dl got fn, /) ) {
+ let filename = line.split(' => ')[1].trim()
+ task.dataset = filename.split('.')[0]
+ task.opt.filename = filename
+ return { type: 'progress', action: 'resolve_dataset', task, }
}
return null
}