Skip to content

Commit

Permalink
[qa] stop updating is_casting_standby / nb_frames when not asked
Browse files Browse the repository at this point in the history
  • Loading branch information
EvanBldy committed Nov 18, 2022
1 parent fc8ceac commit 5f3d0a6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/store/api/assets.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export default {
ready_for: asset.ready_for,
data: asset.data
}
if (asset.is_casting_standby) {
if (asset.is_casting_standby !== undefined) {
data.is_casting_standby = Boolean(asset.is_casting_standby)
}
if (asset.source_id === 'null' || asset.source_id) {
Expand Down
14 changes: 8 additions & 6 deletions src/store/api/shots.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,15 @@ export default {
description: shot.description,
data: shot.data
}
if (shot.is_casting_standby) {
if (shot.is_casting_standby !== undefined) {
data.is_casting_standby = Boolean(shot.is_casting_standby)
}
if (shot.nb_frames) {
data.nb_frames = parseInt(shot.nb_frames)
} else {
data.nb_frames = null
if (shot.nb_frames !== undefined) {
if (shot.nb_frames !== null) {
data.nb_frames = parseInt(shot.nb_frames)
} else {
data.nb_frames = null
}
}
if (
shot.frameOut !== undefined ||
Expand Down Expand Up @@ -108,7 +110,7 @@ export default {
name: episode.name,
description: episode.description
}
if (episode.is_casting_standby) {
if (episode.is_casting_standby !== undefined) {
data.is_casting_standby = Boolean(episode.is_casting_standby)
}
return client.pput(`/api/data/entities/${episode.id}`, data)
Expand Down

0 comments on commit 5f3d0a6

Please sign in to comment.