PHP Fatal error: Uncaught Error: Object of class WP_Error could not be converted to string in wp-content/plugins/indieweb-post-kinds/lib/parse-this/includes/class-parse-this.php:369
Stack trace:
#0 wp-content/plugins/indieweb-post-kinds/lib/parse-this/includes/class-parse-this.php(369): str_replace()
#1 wp-content/plugins/indieweb-post-kinds/lib/parse-this/includes/class-rest-parse-this.php(120): Parse_This->parse()
#2 wp-includes/rest-api/class-wp-rest-server.php(1015): REST_Parse_This::read()
#3 wp-content/plugins/activitypub/includes/rest/class-server.php(29): WP_REST_Server->dispatch()
#4 wp-includes/rest-api/class-wp-rest-server.php(342): Activitypub\Rest\Server->dispatch()
#5 wp-includes/rest-api.php(312): WP_REST_Server->serve_request()
#6 wp-includes/class-wp-hook.php(287): rest_api_loaded()
Affected version shipped with indieweb-post-kinds 3.3.4
Tried also with 95375c08b483b39e00f5c4ed63a284c16c13e8a7
Solution: Catch WP_Error thrown by own/self function redirect()
Error in question is:
PHP_Error Object
(
[errors] => Array
(
[invalid-url] => Array
(
[0] => A valid URL was not provided.
)
[...]
This probably happened because the summary seems to be shortened (by what I don't know) and an URL was cut in the middle. wp_extract_urls() (regex fn) returns the partial $url with content string https://www.gamingonlinu... in this case and yeah… that's not a valid URL.
Trace:
Affected version shipped with
indieweb-post-kinds 3.3.4
Tried also with 95375c08b483b39e00f5c4ed63a284c16c13e8a7Solution: Catch
WP_Error
thrown by own/self functionredirect()
Error in question is:
This probably happened because the summary seems to be shortened (by what I don't know) and an URL was cut in the middle.
wp_extract_urls()
(regex fn) returns the partial$url
with content stringhttps://www.gamingonlinu...
in this case and yeah… that's not a valid URL.