forked from mirrors/gotosocial
Add missing published
field to Announce
This commit is contained in:
parent
af29c06290
commit
b3194f1fee
1 changed files with 4 additions and 4 deletions
|
@ -21,8 +21,6 @@ import (
|
|||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"net/url"
|
||||
|
||||
"github.com/miekg/dns"
|
||||
"github.com/superseriousbusiness/gotosocial/internal/ap"
|
||||
"github.com/superseriousbusiness/gotosocial/internal/config"
|
||||
|
@ -32,6 +30,8 @@ import (
|
|||
"github.com/superseriousbusiness/gotosocial/internal/log"
|
||||
"github.com/superseriousbusiness/gotosocial/internal/uris"
|
||||
"github.com/superseriousbusiness/gotosocial/internal/util"
|
||||
"net/url"
|
||||
"time"
|
||||
)
|
||||
|
||||
func (c *converter) ASRepresentationToAccount(ctx context.Context, accountable ap.Accountable, accountDomain string) (*gtsmodel.Account, error) {
|
||||
|
@ -630,8 +630,8 @@ func (c *converter) ASAnnounceToStatus(ctx context.Context, announceable ap.Anno
|
|||
// Extract published time for the boost.
|
||||
published, err := ap.ExtractPublished(announceable)
|
||||
if err != nil {
|
||||
err = gtserror.Newf("error extracting published: %w", err)
|
||||
return nil, isNew, err
|
||||
//err = gtserror.Newf("error extracting published: %w", err)
|
||||
published = time.Now().UTC()
|
||||
}
|
||||
status.CreatedAt = published
|
||||
status.UpdatedAt = published
|
||||
|
|
Loading…
Reference in a new issue