mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2024-11-24 09:20:59 +00:00
don't error if content property is nil (#436)
This commit is contained in:
parent
73e9cca701
commit
36b2f2b4e6
1 changed files with 1 additions and 1 deletions
|
@ -336,7 +336,7 @@ func ExtractPublicKeyForOwner(i WithPublicKey, forOwner *url.URL) (*rsa.PublicKe
|
||||||
func ExtractContent(i WithContent) (string, error) {
|
func ExtractContent(i WithContent) (string, error) {
|
||||||
contentProperty := i.GetActivityStreamsContent()
|
contentProperty := i.GetActivityStreamsContent()
|
||||||
if contentProperty == nil {
|
if contentProperty == nil {
|
||||||
return "", errors.New("content property was nil")
|
return "", nil
|
||||||
}
|
}
|
||||||
for iter := contentProperty.Begin(); iter != contentProperty.End(); iter = iter.Next() {
|
for iter := contentProperty.Begin(); iter != contentProperty.End(); iter = iter.Next() {
|
||||||
if iter.IsXMLSchemaString() && iter.GetXMLSchemaString() != "" {
|
if iter.IsXMLSchemaString() && iter.GetXMLSchemaString() != "" {
|
||||||
|
|
Loading…
Reference in a new issue