From 4977a733b6f614de868fc405b820d5c66e5bf9b7 Mon Sep 17 00:00:00 2001 From: Harald Eilertsen Date: Sat, 8 May 2021 19:18:38 +0200 Subject: Auto fixup missing return types by Psalm --- includes/concert.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'includes/concert.php') diff --git a/includes/concert.php b/includes/concert.php index d95934e..f19a614 100644 --- a/includes/concert.php +++ b/includes/concert.php @@ -32,6 +32,9 @@ if ( !class_exists('GiglogAdmin_Concert') ) { } + /** + * @return null|self + */ static function find_cid($id) { global $wpdb; @@ -51,7 +54,7 @@ if ( !class_exists('GiglogAdmin_Concert') ) { } } - public static function create($name, $venue, $date, $ticketlink, $eventlink) + public static function create($name, $venue, $date, $ticketlink, $eventlink): ?self { if ( GiglogAdmin_Concert::find($name, $venue, $date) ) { error_log( 'DUPLICATE ROW detected: ' @@ -155,7 +158,7 @@ if ( !class_exists('GiglogAdmin_Concert') ) { return $wpdb->get_results($sql); } - public function save() + public function save(): void { global $wpdb; -- cgit v1.2.3