apply_filters( 'allow_empty_comment', bool $allow_empty_comment, array $commentdata )

Filters whether an empty comment should be allowed.

Parameters

$allow_empty_comment

(bool) Whether to allow empty comments. Default false.

$commentdata

(array) Array of comment data to be sent to wp_insert_comment().

Source

File: wp-includes/comment.php

View on Trac

Changelog

Version Description
5.1.0 Introduced.

© 2003–2021 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/allow_empty_comment