• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Yoast / wordpress-seo / 6987097851

25 Nov 2023 04:49AM UTC coverage: 49.206% (-0.1%) from 49.302%
6987097851

push

github

web-flow
Merge pull request #20878 from Yoast/JRF/ghactions-minor-tweak

GH Actions: update a few links in inline comments

15305 of 31104 relevant lines covered (49.21%)

4.03 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

70.59
/src/presenters/debug/marker-open-presenter.php
1
<?php
2

3
namespace Yoast\WP\SEO\Presenters\Debug;
4

5
use Yoast\WP\SEO\Presenters\Abstract_Indexable_Presenter;
6

7
/**
8
 * Presenter class for the debug open marker.
9
 */
10
final class Marker_Open_Presenter extends Abstract_Indexable_Presenter {
11

12
        /**
13
         * Returns the debug close marker.
14
         *
15
         * @return string The debug close marker.
16
         */
17
        public function present() {
4✔
18
                /**
19
                 * Filter: 'wpseo_debug_markers' - Allow disabling the debug markers.
20
                 *
21
                 * @api bool $show_markers True when the debug markers should be shown.
22
                 */
23
                if ( ! \apply_filters( 'wpseo_debug_markers', true ) ) {
4✔
24
                        return '';
2✔
25
                }
26
                $version_info = 'v' . \WPSEO_VERSION;
2✔
27

28
                if ( $this->helpers->product->is_premium() ) {
2✔
29
                        $version_info = $this->construct_version_info();
×
30
                }
31

32
                return \sprintf(
2✔
33
                        '<!-- This site is optimized with the %1$s %2$s - https://yoast.com/wordpress/plugins/seo/ -->',
2✔
34
                        \esc_html( $this->helpers->product->get_name() ),
2✔
35
                        $version_info
2✔
36
                );
1✔
37
        }
38

39
        /**
40
         * Gets the plugin version information, including the free version if Premium is used.
41
         *
42
         * @return string The constructed version information.
43
         */
44
        private function construct_version_info() {
×
45
                /**
46
                 * Filter: 'wpseo_hide_version' - can be used to hide the Yoast SEO version in the debug marker (only available in Yoast SEO Premium).
47
                 *
48
                 * @api bool
49
                 */
50
                if ( \apply_filters( 'wpseo_hide_version', false ) ) {
×
51
                        return '';
×
52
                }
53

54
                return 'v' . \WPSEO_PREMIUM_VERSION . ' (Yoast SEO v' . \WPSEO_VERSION . ')';
×
55
        }
56

57
        /**
58
         * Gets the raw value of a presentation.
59
         *
60
         * @return string The raw value.
61
         */
62
        public function get() {
2✔
63
                return '';
2✔
64
        }
65
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc