PluginProbe
Assistant – Every Day Productivity Apps / 1.5.5.1
Assistant – Every Day Productivity Apps v1.5.5.1
1.5.5.1 1.5.5 trunk 0.1.0 0.2.0 0.2.1 0.2.2 0.3.0 0.3.1 0.4 0.4.1 0.4.2 0.5.0 0.5.1 0.6.0 0.7.0 0.7.0.2 0.7.0.3 0.7.0.4 0.7.0.5 0.7.0.6 0.7.0.7 0.7.0.8 0.7.0.9 0.7.1 All 72 releases
← All changes | backend/src/Data/Repository/CommentsRepository.php +3 -3 0.5.1 → 1.5.5.1 View file →
@@ -18,9 +18,9 @@
18 18 * @param callable|null $transform
19 19 *
20 20 * @return array|mixed|\WP_Comment|null
21 21 */
22 - public function find( $id, callable $transform = null ) {
22 + public function find( $id, ?callable $transform = null ) {
23 23 $comment = get_comment( $id );
24 24 if ( ! is_null( $transform ) ) {
25 25 $comment = call_user_func( $transform, $comment );
26 26 }
@@ -33,9 +33,9 @@
33 33 * @param callable|null $transform
34 34 *
35 35 * @return array|int
36 36 */
37 - public function find_where( array $args = [], callable $transform = null ) {
37 + public function find_where( array $args = [], ?callable $transform = null ) {
38 38 $comments = $this->query( $args )->get_comments();
39 39 if ( ! is_null( $transform ) ) {
40 40 $comments = array_map( $transform, $comments );
41 41 }
@@ -47,9 +47,9 @@
47 47 * @param callable|null $transform
48 48 *
49 49 * @return Pager
50 50 */
51 - public function paginate( array $args = [], callable $transform = null ) {
51 + public function paginate( array $args = [], ?callable $transform = null ) {
52 52 $args['no_found_rows'] = false; // Make sure to calc the number of found rows.
53 53 $query = $this->query( $args );
54 54
55 55 $pager = new Pager(