*/ public function candidates(string $postType, string $search, bool $caseSensitive, int $limit, int $offset): array { $db = $this->db(); $forms = StoredForms::of($search, $caseSensitive); $likes = array_map( static fn (string $form): string => '%' . $db->esc_like($form) . '%', $forms ); $sql = "SELECT ID FROM {$db->posts} WHERE post_type = %s" . ' AND post_status NOT IN (' . PostStatuses::NOT_CONTENT . ')' . ' AND post_content LIKE %s AND (' . implode(' OR ', array_fill(0, count($likes), 'post_content LIKE %s')) . ')'; $args = array_merge([$postType, '%' . $db->esc_like('