@pixwel/pixwel-sdk 2.1.41 → 2.1.43

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,13 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var cov_twzg327in = function () {
4
- var path = '/Users/jeff/www/pixwel/platform2/pixwel-sdk/src/TimeFormat.js',
5
- hash = 'e088183d370b3db442e98f1887a6e3c60f695efd',
3
+ var cov_1lrngkoks3 = function () {
4
+ var path = '/Users/jeff/www/platform-x4/pixwel-sdk/src/TimeFormat.js',
5
+ hash = 'e2effadd0abac89b263f585788c51e59634b3917',
6
6
  Function = function () {}.constructor,
7
7
  global = new Function('return this')(),
8
8
  gcv = '__coverage__',
9
9
  coverageData = {
10
- path: '/Users/jeff/www/pixwel/platform2/pixwel-sdk/src/TimeFormat.js',
10
+ path: '/Users/jeff/www/platform-x4/pixwel-sdk/src/TimeFormat.js',
11
11
  statementMap: {
12
12
  '0': {
13
13
  start: {
@@ -880,85 +880,85 @@ var cov_twzg327in = function () {
880
880
  Object.defineProperty(exports, "__esModule", {
881
881
  value: true
882
882
  });
883
- var stringRegex = (cov_twzg327in.s[0]++, /^(\d+):(\d+):(\d+)[,|.](\d{2,3})?$/);
883
+ var stringRegex = (cov_1lrngkoks3.s[0]++, /^(\d+):(\d+):(\d+)[,|.](\d{2,3})?$/);
884
884
 
885
885
  exports.default = {
886
886
  isValidTime: function isValidTime(time) {
887
- cov_twzg327in.f[0]++;
888
- cov_twzg327in.s[1]++;
887
+ cov_1lrngkoks3.f[0]++;
888
+ cov_1lrngkoks3.s[1]++;
889
889
 
890
890
  return !!time.match(stringRegex);
891
891
  },
892
892
  timeToTimestamp: function timeToTimestamp(time) {
893
- cov_twzg327in.f[1]++;
893
+ cov_1lrngkoks3.f[1]++;
894
894
 
895
- var match = (cov_twzg327in.s[2]++, time.match(stringRegex));
896
- cov_twzg327in.s[3]++;
895
+ var match = (cov_1lrngkoks3.s[2]++, time.match(stringRegex));
896
+ cov_1lrngkoks3.s[3]++;
897
897
  if (!match) {
898
- cov_twzg327in.b[0][0]++;
899
- cov_twzg327in.s[4]++;
898
+ cov_1lrngkoks3.b[0][0]++;
899
+ cov_1lrngkoks3.s[4]++;
900
900
 
901
901
  return 0;
902
902
  } else {
903
- cov_twzg327in.b[0][1]++;
903
+ cov_1lrngkoks3.b[0][1]++;
904
904
  }
905
- var precision = (cov_twzg327in.s[5]++, match[4].length === 2 ? (cov_twzg327in.b[1][0]++, 100) : (cov_twzg327in.b[1][1]++, 1000));
906
- cov_twzg327in.s[6]++;
905
+ var precision = (cov_1lrngkoks3.s[5]++, match[4].length === 2 ? (cov_1lrngkoks3.b[1][0]++, 100) : (cov_1lrngkoks3.b[1][1]++, 1000));
906
+ cov_1lrngkoks3.s[6]++;
907
907
  return parseInt(match[1], 10) * 60 * 60 + parseInt(match[2], 10) * 60 + parseInt(match[3], 10) + parseInt(match[4], 10) / precision;
908
908
  },
909
909
  timestampToTime: function timestampToTime(second, decimalMark) {
910
- cov_twzg327in.f[2]++;
910
+ cov_1lrngkoks3.f[2]++;
911
911
 
912
- var hours = (cov_twzg327in.s[7]++, ~~(second / 3600));
913
- var min = (cov_twzg327in.s[8]++, ~~(second / 60) % 60);
914
- var sec = (cov_twzg327in.s[9]++, second % 60);
915
- var fixedSec = (cov_twzg327in.s[10]++, sec.toFixed(3).replace('.', decimalMark ? (cov_twzg327in.b[2][0]++, decimalMark) : (cov_twzg327in.b[2][1]++, ',')));
916
- cov_twzg327in.s[11]++;
917
- return (hours < 10 ? (cov_twzg327in.b[3][0]++, '0' + hours) : (cov_twzg327in.b[3][1]++, hours)) + ":" + (min < 10 ? (cov_twzg327in.b[4][0]++, '0' + min) : (cov_twzg327in.b[4][1]++, min)) + ':' + (sec < 10 ? (cov_twzg327in.b[5][0]++, '0' + fixedSec) : (cov_twzg327in.b[5][1]++, fixedSec));
912
+ var hours = (cov_1lrngkoks3.s[7]++, ~~(second / 3600));
913
+ var min = (cov_1lrngkoks3.s[8]++, ~~(second / 60) % 60);
914
+ var sec = (cov_1lrngkoks3.s[9]++, second % 60);
915
+ var fixedSec = (cov_1lrngkoks3.s[10]++, sec.toFixed(3).replace('.', decimalMark ? (cov_1lrngkoks3.b[2][0]++, decimalMark) : (cov_1lrngkoks3.b[2][1]++, ',')));
916
+ cov_1lrngkoks3.s[11]++;
917
+ return (hours < 10 ? (cov_1lrngkoks3.b[3][0]++, '0' + hours) : (cov_1lrngkoks3.b[3][1]++, hours)) + ":" + (min < 10 ? (cov_1lrngkoks3.b[4][0]++, '0' + min) : (cov_1lrngkoks3.b[4][1]++, min)) + ':' + (sec < 10 ? (cov_1lrngkoks3.b[5][0]++, '0' + fixedSec) : (cov_1lrngkoks3.b[5][1]++, fixedSec));
918
918
  },
919
919
  timeDiff: function timeDiff(time1, time2) {
920
- cov_twzg327in.f[3]++;
921
- cov_twzg327in.s[12]++;
920
+ cov_1lrngkoks3.f[3]++;
921
+ cov_1lrngkoks3.s[12]++;
922
922
 
923
- if ((cov_twzg327in.b[7][0]++, time1 === undefined) || (cov_twzg327in.b[7][1]++, time2 === undefined)) {
924
- cov_twzg327in.b[6][0]++;
925
- cov_twzg327in.s[13]++;
923
+ if ((cov_1lrngkoks3.b[7][0]++, time1 === undefined) || (cov_1lrngkoks3.b[7][1]++, time2 === undefined)) {
924
+ cov_1lrngkoks3.b[6][0]++;
925
+ cov_1lrngkoks3.s[13]++;
926
926
 
927
927
  return 0;
928
928
  } else {
929
- cov_twzg327in.b[6][1]++;
929
+ cov_1lrngkoks3.b[6][1]++;
930
930
  }
931
- cov_twzg327in.s[14]++;
931
+ cov_1lrngkoks3.s[14]++;
932
932
  return this.timestampDiff(this.timeToTimestamp(time1), this.timeToTimestamp(time2));
933
933
  },
934
934
  timestampDiff: function timestampDiff(time1, time2) {
935
- cov_twzg327in.f[4]++;
936
- cov_twzg327in.s[15]++;
935
+ cov_1lrngkoks3.f[4]++;
936
+ cov_1lrngkoks3.s[15]++;
937
937
 
938
- if ((cov_twzg327in.b[9][0]++, time1 === undefined) || (cov_twzg327in.b[9][1]++, time2 === undefined) || (cov_twzg327in.b[9][2]++, time1 === time2)) {
939
- cov_twzg327in.b[8][0]++;
940
- cov_twzg327in.s[16]++;
938
+ if ((cov_1lrngkoks3.b[9][0]++, time1 === undefined) || (cov_1lrngkoks3.b[9][1]++, time2 === undefined) || (cov_1lrngkoks3.b[9][2]++, time1 === time2)) {
939
+ cov_1lrngkoks3.b[8][0]++;
940
+ cov_1lrngkoks3.s[16]++;
941
941
 
942
942
  return 0;
943
943
  } else {
944
- cov_twzg327in.b[8][1]++;
944
+ cov_1lrngkoks3.b[8][1]++;
945
945
  }
946
- var diff = (cov_twzg327in.s[17]++, time2 - time1);
947
- cov_twzg327in.s[18]++;
946
+ var diff = (cov_1lrngkoks3.s[17]++, time2 - time1);
947
+ cov_1lrngkoks3.s[18]++;
948
948
  return Math.round(Math.max(-1, Math.min(1, diff)) * 10) / 10;
949
949
  },
950
950
  startTime: function startTime(line) {
951
- cov_twzg327in.f[5]++;
951
+ cov_1lrngkoks3.f[5]++;
952
952
 
953
- var timestamp = (cov_twzg327in.s[19]++, this.timeToTimestamp(line.startTime) + ((cov_twzg327in.b[10][0]++, line.inOffset) || (cov_twzg327in.b[10][1]++, 0)));
954
- cov_twzg327in.s[20]++;
953
+ var timestamp = (cov_1lrngkoks3.s[19]++, this.timeToTimestamp(line.startTime) + ((cov_1lrngkoks3.b[10][0]++, line.inOffset) || (cov_1lrngkoks3.b[10][1]++, 0)));
954
+ cov_1lrngkoks3.s[20]++;
955
955
  return this.timestampToTime(timestamp);
956
956
  },
957
957
  stopTime: function stopTime(line) {
958
- cov_twzg327in.f[6]++;
958
+ cov_1lrngkoks3.f[6]++;
959
959
 
960
- var timestamp = (cov_twzg327in.s[21]++, this.timeToTimestamp(line.stopTime) + ((cov_twzg327in.b[11][0]++, line.outOffset) || (cov_twzg327in.b[11][1]++, 0)));
961
- cov_twzg327in.s[22]++;
960
+ var timestamp = (cov_1lrngkoks3.s[21]++, this.timeToTimestamp(line.stopTime) + ((cov_1lrngkoks3.b[11][0]++, line.outOffset) || (cov_1lrngkoks3.b[11][1]++, 0)));
961
+ cov_1lrngkoks3.s[22]++;
962
962
  return this.timestampToTime(timestamp);
963
963
  }
964
964
  };
@@ -1,13 +1,13 @@
1
1
  "use strict";
2
2
 
3
- var cov_rbwlazav = function () {
4
- var path = "/Users/jeff/www/pixwel/platform2/pixwel-sdk/src/fileType.js",
5
- hash = "8c0972cb3582b18ca41711ec8a591eefb67ebd44",
3
+ var cov_1gj0nbe3ht = function () {
4
+ var path = "/Users/jeff/www/platform-x4/pixwel-sdk/src/fileType.js",
5
+ hash = "2236cafb60e357672dac6e72d52820a9516c1ee1",
6
6
  Function = function () {}.constructor,
7
7
  global = new Function('return this')(),
8
8
  gcv = "__coverage__",
9
9
  coverageData = {
10
- path: "/Users/jeff/www/pixwel/platform2/pixwel-sdk/src/fileType.js",
10
+ path: "/Users/jeff/www/platform-x4/pixwel-sdk/src/fileType.js",
11
11
  statementMap: {
12
12
  "0": {
13
13
  start: {
@@ -296,9 +296,9 @@ var cov_rbwlazav = function () {
296
296
  return coverage[path] = coverageData;
297
297
  }();
298
298
 
299
- var extname = (cov_rbwlazav.s[0]++, require("path").extname);
299
+ var extname = (cov_1gj0nbe3ht.s[0]++, require("path").extname);
300
300
 
301
- var TYPES = (cov_rbwlazav.s[1]++, {
301
+ var TYPES = (cov_1gj0nbe3ht.s[1]++, {
302
302
  document: ["doc", "docx", "xls", "xlsx", "txt", "pdf", "ppt", "pptx"],
303
303
 
304
304
  video: ["mov", "mp4", "m4v", "mpg", "mxf"],
@@ -311,50 +311,50 @@ var TYPES = (cov_rbwlazav.s[1]++, {
311
311
  });
312
312
 
313
313
  function extensionType(extension) {
314
- cov_rbwlazav.f[0]++;
315
- cov_rbwlazav.s[2]++;
314
+ cov_1gj0nbe3ht.f[0]++;
315
+ cov_1gj0nbe3ht.s[2]++;
316
316
 
317
317
  for (var type in TYPES) {
318
- cov_rbwlazav.s[3]++;
318
+ cov_1gj0nbe3ht.s[3]++;
319
319
 
320
320
  if (TYPES[type].indexOf(extension) > -1) {
321
- cov_rbwlazav.b[0][0]++;
322
- cov_rbwlazav.s[4]++;
321
+ cov_1gj0nbe3ht.b[0][0]++;
322
+ cov_1gj0nbe3ht.s[4]++;
323
323
 
324
324
  return type;
325
325
  } else {
326
- cov_rbwlazav.b[0][1]++;
326
+ cov_1gj0nbe3ht.b[0][1]++;
327
327
  }
328
328
  }
329
329
  }
330
330
 
331
331
  function extension(path) {
332
- cov_rbwlazav.f[1]++;
333
- cov_rbwlazav.s[5]++;
332
+ cov_1gj0nbe3ht.f[1]++;
333
+ cov_1gj0nbe3ht.s[5]++;
334
334
 
335
335
  return extname(path.split("?")[0].toLowerCase()).substring(1);
336
336
  }
337
337
 
338
338
  function mediaType(path) {
339
- cov_rbwlazav.f[2]++;
339
+ cov_1gj0nbe3ht.f[2]++;
340
340
 
341
- var type = (cov_rbwlazav.s[6]++, extensionType(extension(path)));
341
+ var type = (cov_1gj0nbe3ht.s[6]++, extensionType(extension(path)));
342
342
 
343
- cov_rbwlazav.s[7]++;
343
+ cov_1gj0nbe3ht.s[7]++;
344
344
  if (type) {
345
- cov_rbwlazav.b[1][0]++;
346
- cov_rbwlazav.s[8]++;
345
+ cov_1gj0nbe3ht.b[1][0]++;
346
+ cov_1gj0nbe3ht.s[8]++;
347
347
 
348
348
  return type;
349
349
  } else {
350
- cov_rbwlazav.b[1][1]++;
350
+ cov_1gj0nbe3ht.b[1][1]++;
351
351
  }
352
352
 
353
- cov_rbwlazav.s[9]++;
353
+ cov_1gj0nbe3ht.s[9]++;
354
354
  throw new Error("Unknown extension '" + extension + "'");
355
355
  }
356
356
 
357
- cov_rbwlazav.s[10]++;
357
+ cov_1gj0nbe3ht.s[10]++;
358
358
  module.exports = {
359
359
  extension: extension,
360
360
  extensionType: extensionType,
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@pixwel/pixwel-sdk",
3
3
  "description": "",
4
- "version": "2.1.41",
4
+ "version": "2.1.43",
5
5
  "author": "Pixwel",
6
6
  "license": "UNLICENSED",
7
7
  "main": "./dist/index.js",
8
8
  "scripts": {
9
- "build": "npx babel-cli -d dist index.js src/*.js",
10
- "watch": "npx babel-cli -w -d dist index.js src/*.js",
9
+ "build": "npx babel -d dist index.js src/*.js",
10
+ "watch": "npx babel -w -d dist index.js src/*.js",
11
11
  "test": "npx jest --coverage",
12
12
  "debug": "node --inspect-brk node_modules/.bin/jest --watch --runInBand"
13
13
  },
package/src/Ingest.js CHANGED
@@ -34,9 +34,47 @@ export default class Ingest extends Model {
34
34
  return [
35
35
  ingest.asset.project.studio.slug,
36
36
  ingest.asset.project.slug,
37
- ingest.asset.type
37
+ ingest.asset.type,
38
38
  ].join("/");
39
39
  }
40
+
41
+ static assetType(asset, types) {
42
+ if (/trailer/.test(asset.type)) {
43
+ return false;
44
+ }
45
+
46
+ let matchingType = _.find(types, { name: asset.type });
47
+ if (!matchingType) {
48
+ throw new Error(`Asset type "${asset.type}" could not be found`);
49
+ }
50
+
51
+ return (
52
+ matchingType.file || matchingType.name.replace(".", "-").toUpperCase()
53
+ );
54
+ }
55
+
56
+ static assetTitle(asset) {
57
+ let prefix = "";
58
+ let name = asset.slug.toUpperCase().replace("INT-L", "INTL");
59
+ if (/trailer/.test(asset.type)) {
60
+ switch (asset.type) {
61
+ case "trailer.intl":
62
+ prefix = "ITR-";
63
+ name = name.replace(/INTL-TRAILER-/, "");
64
+ break;
65
+ case "trailer":
66
+ prefix = "TR-";
67
+ name = name.replace(/TRAILER-/, "");
68
+ break;
69
+ case "trailer.us":
70
+ prefix = "DTR-";
71
+ name = name.replace(/DOMESTIC-TRAILER-/, "");
72
+ break;
73
+ }
74
+ }
75
+ return prefix + name;
76
+ }
77
+
40
78
  /**
41
79
  * Create a File from an Ingest object with path and filename
42
80
  *
@@ -73,15 +111,15 @@ export default class Ingest extends Model {
73
111
  Standard: null,
74
112
  SubDub: {
75
113
  sub: null,
76
- dub: null
114
+ dub: null,
77
115
  },
78
116
  Resolution: null,
79
117
  "Frame Mode": null,
80
118
  Framerate: null,
81
119
  Text: null,
82
120
  Codec: null,
83
- Extra: []
84
- }
121
+ Extra: [],
122
+ },
85
123
  };
86
124
  options = _.merge(defaults, options);
87
125
 
@@ -105,43 +143,6 @@ export default class Ingest extends Model {
105
143
  throw new Error("missing options.tags[Frame Mode]");
106
144
  }
107
145
 
108
- function assetType(asset, types) {
109
- if (/trailer/.test(asset.type)) {
110
- return false;
111
- }
112
-
113
- let matchingType = _.find(types, { name: asset.type });
114
- if (!matchingType) {
115
- throw new Error(`Asset type "${asset.type}" could not be found`);
116
- }
117
-
118
- return (
119
- matchingType.file || matchingType.name.replace(".", "-").toUpperCase()
120
- );
121
- }
122
-
123
- function assetTitle(asset) {
124
- let prefix = "";
125
- let name = asset.slug.toUpperCase().replace("INT-L", "INTL");
126
- if (/trailer/.test(asset.type)) {
127
- switch (asset.type) {
128
- case "trailer.intl":
129
- prefix = "ITR-";
130
- name = name.replace(/INTL-TRAILER-/, "");
131
- break;
132
- case "trailer":
133
- prefix = "TR-";
134
- name = name.replace(/TRAILER-/, "");
135
- break;
136
- case "trailer.us":
137
- prefix = "DTR-";
138
- name = name.replace(/DOMESTIC-TRAILER-/, "");
139
- break;
140
- }
141
- }
142
- return prefix + name;
143
- }
144
-
145
146
  function runningTime(asset) {
146
147
  let matches = asset.type.match(/^film-clip|^featurette/);
147
148
  if (!matches) {
@@ -169,7 +170,7 @@ export default class Ingest extends Model {
169
170
  country = "";
170
171
  }
171
172
  return [language, country]
172
- .filter(str => {
173
+ .filter((str) => {
173
174
  return !!str && str !== "WW";
174
175
  })
175
176
  .join("-");
@@ -194,22 +195,30 @@ export default class Ingest extends Model {
194
195
 
195
196
  let tags = options.tags;
196
197
 
198
+ if (tags.Aspect === "scope") {
199
+ tags.Extra.push("scope");
200
+ }
201
+
202
+ if (tags.Aspect === "flat") {
203
+ tags.Extra.push("flat");
204
+ }
205
+
197
206
  let parts = [
198
- asset.project.filePrefix,
199
- assetType(asset, allTypes),
200
- assetTitle(asset),
201
- runningTime(asset),
202
- locale(options.country, options.language),
203
- textType(tags.SubDub, tags.Text),
204
- tags.Extra.join("_"),
205
- options.version,
206
- tags.Codec
207
- ];
207
+ asset.project.filePrefix,
208
+ Ingest.assetType(asset, allTypes),
209
+ Ingest.assetTitle(asset),
210
+ runningTime(asset),
211
+ locale(options.country, options.language),
212
+ textType(tags.SubDub, tags.Text),
213
+ tags.Extra.join("_"),
214
+ options.version,
215
+ tags.Codec,
216
+ ];
208
217
 
209
218
  parts = _(parts)
210
219
  .flatten()
211
220
  .filter()
212
- .map(part => part.toUpperCase());
221
+ .map((part) => part.toUpperCase());
213
222
 
214
223
  let requiredInfo = tags.Resolution && tags["Frame Mode"] && tags.Framerate;
215
224
 
@@ -219,21 +228,29 @@ export default class Ingest extends Model {
219
228
  parts = parts.push(tags.Resolution);
220
229
  }
221
230
 
222
- if (mediaType === 'video' && tags.Aspect && tags.Resolution && tags.Standard && tags.Framerate && tags['Frame Mode']) {
223
-
224
- let [ width, height ] = tags.Resolution.split('x');
231
+ if (
232
+ mediaType === "video" &&
233
+ tags.Aspect &&
234
+ tags.Resolution &&
235
+ tags.Standard &&
236
+ tags.Framerate &&
237
+ tags["Frame Mode"]
238
+ ) {
239
+ let [width, height] = tags.Resolution.split("x");
225
240
 
226
- let aspect = tags.Aspect.replace(':', 'X');
241
+ let aspect = tags.Aspect.replace(":", "X");
227
242
  let standard = tags.Standard.toUpperCase();
228
243
  let frameModeToken = tags["Frame Mode"][0].toLowerCase();
229
244
  let frameRate = tags.Framerate.replace(".", "");
230
245
 
231
- if ((height === '576' || height === '486') && (tags.Aspect === '4:3' || tags.Aspect === '16:9')) {
246
+ if (
247
+ (height === "576" || height === "486") &&
248
+ (tags.Aspect === "4:3" || tags.Aspect === "16:9")
249
+ ) {
232
250
  parts = parts.push(`${standard}-${aspect}`);
233
251
  }
234
252
 
235
253
  parts = parts.push(`${height}${frameModeToken}${frameRate}`);
236
-
237
254
  }
238
255
 
239
256
  let name = parts.join("_");
@@ -264,7 +281,7 @@ export default class Ingest extends Model {
264
281
  Usage: null,
265
282
  Extra: [],
266
283
  Framerate: null,
267
- Duration: null
284
+ Duration: null,
268
285
  };
269
286
 
270
287
  let tags = {};
@@ -281,7 +298,7 @@ export default class Ingest extends Model {
281
298
  if (!Array.isArray(info["media"]["track"])) {
282
299
  general = info["media"]["track"];
283
300
  } else {
284
- general = _.find(info["media"]["track"], { '@type': "General" });
301
+ general = _.find(info["media"]["track"], { "@type": "General" });
285
302
  }
286
303
 
287
304
  switch (mediaType) {
@@ -305,11 +322,11 @@ export default class Ingest extends Model {
305
322
  Height: "",
306
323
  Width: "",
307
324
  FrameRate: "",
308
- ScanType: ""
325
+ ScanType: "",
309
326
  };
310
327
 
311
328
  let media = _.find(info["media"]["track"], {
312
- '@type': mediaType
329
+ "@type": mediaType,
313
330
  });
314
331
  media = _.merge({}, mediainfoDefaults, media);
315
332
 
@@ -401,8 +418,8 @@ export default class Ingest extends Model {
401
418
  case "1.000":
402
419
  tags.Aspect = "1:1";
403
420
  break;
404
- case '1.333':
405
- case '1.317':
421
+ case "1.333":
422
+ case "1.317":
406
423
  case "1.347":
407
424
  tags.Aspect = "4:3";
408
425
  break;
@@ -432,9 +449,9 @@ export default class Ingest extends Model {
432
449
  let ingest = {
433
450
  selected: {
434
451
  download: {
435
- tags: tags
436
- }
437
- }
452
+ tags: tags,
453
+ },
454
+ },
438
455
  };
439
456
 
440
457
  return ingest;
@@ -450,10 +467,10 @@ export default class Ingest extends Model {
450
467
  let tags = {
451
468
  SubDub: {
452
469
  sub: null,
453
- dub: null
454
- }
470
+ dub: null,
471
+ },
455
472
  };
456
- filename.file.tags.forEach(tag => {
473
+ filename.file.tags.forEach((tag) => {
457
474
  let foundTag = _.find(allTags, { name: tag });
458
475
  if (foundTag) {
459
476
  if (foundTag.type == "SubDub") {
@@ -472,10 +489,10 @@ export default class Ingest extends Model {
472
489
  let ingest = {
473
490
  selected: {
474
491
  download: {
475
- tags: tags
492
+ tags: tags,
476
493
  },
477
- preview: {}
478
- }
494
+ preview: {},
495
+ },
479
496
  };
480
497
  if (
481
498
  filename.file.tags.includes("sub") &&
@@ -524,8 +541,8 @@ export default class Ingest extends Model {
524
541
  workRequest: this.workRequest,
525
542
  verified: true,
526
543
  embargo: {
527
- event: false
528
- }
544
+ event: false,
545
+ },
529
546
  });
530
547
 
531
548
  if (this.selected.download.embargo.end) {
@@ -554,28 +571,28 @@ export default class Ingest extends Model {
554
571
  download: {
555
572
  enabled: true,
556
573
  tags: {
557
- Extra: []
574
+ Extra: [],
558
575
  },
559
576
  embargo: {
560
- enabled: false
561
- }
577
+ enabled: false,
578
+ },
562
579
  },
563
580
  preview: {
564
581
  enabled: false,
565
582
  revision: "Final",
566
583
  type: "none",
567
584
  embargo: {
568
- enabled: false
569
- }
585
+ enabled: false,
586
+ },
570
587
  },
571
588
  thumbnail: {
572
589
  enabled: false,
573
- position: 50
590
+ position: 50,
574
591
  },
575
592
  autosub: {
576
- enabled: false
577
- }
578
- }
593
+ enabled: false,
594
+ },
595
+ },
579
596
  };
580
597
 
581
598
  let ingest = _.merge(defaults, filename, original, mediainfo);
@@ -606,11 +623,15 @@ export default class Ingest extends Model {
606
623
 
607
624
  if (original.context.tag) {
608
625
  ingest.selected.download.tags.Extra = [];
609
- ingest.selected.download.tags.Extra = ingest.selected.download.tags.Extra.concat(original.context.tag);
626
+ ingest.selected.download.tags.Extra =
627
+ ingest.selected.download.tags.Extra.concat(original.context.tag);
610
628
  }
611
629
 
612
630
  if (original.context.revision) {
613
- ingest.selected.download.version = original.context.revision === 1 ? 'REV' : 'REV' + String(original.context.revision);
631
+ ingest.selected.download.version =
632
+ original.context.revision === 1
633
+ ? "REV"
634
+ : "REV" + String(original.context.revision);
614
635
  }
615
636
 
616
637
  if (order.territory) {
@@ -626,7 +647,7 @@ export default class Ingest extends Model {
626
647
  if (order.isSub() || order.isDub()) {
627
648
  ingest.selected.download.tags.SubDub = {
628
649
  sub: order.isSub(),
629
- dub: order.isDub()
650
+ dub: order.isDub(),
630
651
  };
631
652
  }
632
653
  if (order.isSub()) {
@@ -653,7 +674,7 @@ export default class Ingest extends Model {
653
674
  function flatValues(data) {
654
675
  let copy = clone(data);
655
676
  if (copy.SubDub) {
656
- copy.SubDub = keys(filter(val => !!val, copy.SubDub));
677
+ copy.SubDub = keys(filter((val) => !!val, copy.SubDub));
657
678
  }
658
679
  return flatten(values(copy));
659
680
  }
package/update-sdk.sh CHANGED
@@ -6,5 +6,5 @@ npm run build
6
6
  npm publish
7
7
 
8
8
  ( cd ../slurpee2 && pnpm i @pixwel/pixwel-sdk )
9
- ( cd ../slurpee3/createFile && pnpm i @pixwel/pixwel-sdk)
9
+ ( cd ../slurpee3/workflows/encodes/createFile && pnpm i @pixwel/pixwel-sdk)
10
10
  ( cd ../ui && pnpm i @pixwel/pixwel-sdk)