php – Output results of a search for usage of a pardot-form

I’m always down to learn better ways of doing thing and I wanted to see if I can get an input from the community to see if there is a way that I can improve this function:

function pardot_dashboard_query()
    $args = (
        's'         => '<!-- wp:acf/pardot-form ',
        'sentence'  => 1,
        'post_type' => (
    $pardot_posts = get_posts($args);
    if (!$pardot_posts) {
        echo 'There are no active Pardot Forms.';
    echo '<p>The Pardot Form is active on the following pages/posts:</p>'; ?>
        <?php foreach ($pardot_posts as $post): ?>
            <li><a href="<?= $post->guid ?>"><?= $post->post_title ?: 'No title available' ?><?= ' (' . ucfirst($post->post_type) . ')' ?></a></li>
        <?php endforeach; ?>

If there are other means of outputs and or ways to shrink it down – All help will be appreciated!