videos never published should not be processed instead published

This commit is contained in:
Niko Storni 2019-05-07 22:07:44 +02:00
parent 75364805a5
commit 1f7017f3d0

View file

@ -294,7 +294,7 @@ func (v *YoutubeVideo) Sync(daemon *jsonrpc.Client, params SyncParams, existingV
v.maxVideoSize = int64(params.MaxVideoSize) * 1024 * 1024 v.maxVideoSize = int64(params.MaxVideoSize) * 1024 * 1024
v.maxVideoLength = params.MaxVideoLength v.maxVideoLength = params.MaxVideoLength
v.lbryChannelID = params.ChannelID v.lbryChannelID = params.ChannelID
if reprocess { if reprocess && existingVideoData != nil && existingVideoData.Published {
summary, err := v.reprocess(daemon, params, existingVideoData) summary, err := v.reprocess(daemon, params, existingVideoData)
return summary, err return summary, err
} }
@ -302,7 +302,6 @@ func (v *YoutubeVideo) Sync(daemon *jsonrpc.Client, params SyncParams, existingV
} }
func (v *YoutubeVideo) downloadAndPublish(daemon *jsonrpc.Client, params SyncParams) (*SyncSummary, error) { func (v *YoutubeVideo) downloadAndPublish(daemon *jsonrpc.Client, params SyncParams) (*SyncSummary, error) {
//download and thumbnail can be done in parallel
err := v.download() err := v.download()
if err != nil { if err != nil {
return nil, errors.Prefix("download error", err) return nil, errors.Prefix("download error", err)