| Conditions | 2 |
| Paths | 2 |
| Total Lines | 19 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 19 | protected function get_root_element() { |
||
| 20 | |||
| 21 | if ( ! isset( $this->root ) ) { |
||
| 22 | |||
| 23 | $sitemap_index_xsl_url = $this->finder->construct_sitemap_url( 'sitemap-index.xsl' ); |
||
| 24 | $jetpack_version = JETPACK__VERSION; |
||
| 25 | |||
| 26 | $this->root = array( |
||
|
|
|||
| 27 | "<!-- generator='jetpack-{$jetpack_version}' -->" . PHP_EOL |
||
| 28 | . "<?xml-stylesheet type='text/xsl' href='{$sitemap_index_xsl_url}'?>" . PHP_EOL |
||
| 29 | . "<sitemapindex xmlns='http://www.sitemaps.org/schemas/sitemap/0.9'>" . PHP_EOL, |
||
| 30 | '</sitemapindex>' |
||
| 31 | ); |
||
| 32 | |||
| 33 | $this->byte_capacity -= strlen( join( '', $this->root ) ); |
||
| 34 | } |
||
| 35 | |||
| 36 | return $this->root; |
||
| 37 | } |
||
| 38 | } |
||
| 39 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..