Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
69ad13848b | ||
|
|
e496ad670a | ||
|
|
9d8eb32f9f |
No files matched your search
+1
-1
@@ -169,7 +169,7 @@ func (s *Sync) ensureEnoughUTXOs() error {
|
||||
|
||||
for _, utxo := range *utxolist {
|
||||
amount, _ := strconv.ParseFloat(utxo.Amount, 64)
|
||||
if !utxo.IsClaim && !utxo.IsSupport && !utxo.IsUpdate && amount != 0.0 {
|
||||
if !utxo.IsClaim && !utxo.IsSupport && !utxo.IsUpdate && amount > 0.001 {
|
||||
count++
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -480,7 +480,7 @@ func (s *Sync) updateRemoteDB(claims []jsonrpc.Claim) (total, fixed, removed int
|
||||
if claimIDDiffers {
|
||||
log.Debugf("%s: Mismatch in database for claimID. DB: %s - Blockchain: %s", videoID, pv.ClaimID, c.ClaimID)
|
||||
}
|
||||
if claimIDDiffers {
|
||||
if claimNameDiffers {
|
||||
log.Debugf("%s: Mismatch in database for claimName. DB: %s - Blockchain: %s", videoID, pv.ClaimName, c.Name)
|
||||
}
|
||||
if claimMarkedUnpublished {
|
||||
|
||||
@@ -71,6 +71,8 @@ func SanitizeTags(tags []string, youtubeChannelID string) ([]string, error) {
|
||||
return sanitizedTags, nil
|
||||
}
|
||||
|
||||
const TagMaxLength = 255
|
||||
|
||||
func normalizeTag(t string) (string, error) {
|
||||
t = strings.ToLower(t)
|
||||
multipleSpaces := regexp.MustCompile(`\s{2,}`)
|
||||
@@ -87,7 +89,10 @@ func normalizeTag(t string) (string, error) {
|
||||
if weirdChars.MatchString(t) {
|
||||
log.Debugf("tag '%s' has weird stuff in it, skipping\n", t)
|
||||
return "", nil
|
||||
|
||||
}
|
||||
if len(t) > TagMaxLength {
|
||||
log.Debugf("tag '%s' is too long, skipping\n", t)
|
||||
return "", nil
|
||||
}
|
||||
return t, nil
|
||||
}
|
||||
|
||||
+5
-4
@@ -61,10 +61,11 @@ func (u *thumbnailUploader) uploadThumbnail() error {
|
||||
uploader := s3manager.NewUploader(s3Session)
|
||||
|
||||
_, err = uploader.Upload(&s3manager.UploadInput{
|
||||
Bucket: aws.String("thumbnails.lbry.com"),
|
||||
Key: key,
|
||||
Body: thumb,
|
||||
ACL: aws.String("public-read"),
|
||||
Bucket: aws.String("thumbnails.lbry.com"),
|
||||
Key: key,
|
||||
Body: thumb,
|
||||
ACL: aws.String("public-read"),
|
||||
ContentType: aws.String("image/jpeg"),
|
||||
})
|
||||
u.mirroredUrl = ThumbnailEndpoint + u.name
|
||||
return errors.Err(err)
|
||||
|
||||
Reference in new issue
Block a user