Skip to content

Commit

Permalink
Force update live boolean
Browse files Browse the repository at this point in the history
  • Loading branch information
Chocobozzz committed Jan 26, 2021
1 parent fd0fdc4 commit 5d84d71
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions client/src/app/+videos/+video-edit/video-update.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,13 +137,10 @@ export class VideoUpdateComponent extends FormReactive implements OnInit {
if (!this.liveVideo) return of(undefined)

const liveVideoUpdate: LiveVideoUpdate = {
saveReplay: this.form.value.saveReplay,
permanentLive: this.form.value.permanentLive
saveReplay: !!this.form.value.saveReplay,
permanentLive: !!this.form.value.permanentLive
}

console.log(liveVideoUpdate)
console.log(this.form.value)

// Don't update live attributes if they did not change
const liveChanged = Object.keys(liveVideoUpdate)
.some(key => this.liveVideo[key] !== liveVideoUpdate[key])
Expand Down

0 comments on commit 5d84d71

Please sign in to comment.