Skip to content

Commit

Permalink
fix: correctly resolve homepage.description (#92)
Browse files Browse the repository at this point in the history
* Add fix for homepage_description

* chore: add changelog

---------

Co-authored-by: Dovid Levine <[email protected]>
  • Loading branch information
offminded and justlevine authored May 11, 2024
1 parent 29348fa commit 73b86d3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Changelog

## [Unreleased]
- fix: Correctly resolve `rankMathSettings.homepage.description` field. Props @offminded 🙌
- chore: Update Composer dev-dependencies to latest versions and address uncovered lints.
- tests: Update compatibility with `[email protected]`.

Expand Down
2 changes: 1 addition & 1 deletion src/Model/Settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ private function meta_local_fields(): array {
private function meta_homepage_fields(): ?array {
return 'page' !== get_option( 'show_on_front' ) ? [
'advancedRobotsMeta' => $this->advanced_robots_meta( 'homepage_advanced_robots' ),
'description' => ! empty( $this->data['titles']['homepage_description'] ) ? $this->data['titles']['author_archive_description'] : null,
'description' => ! empty( $this->data['titles']['homepage_description'] ) ? $this->data['titles']['homepage_description'] : null,
'hasCustomRobotsMeta' => ! empty( $this->data['titles']['homepage_custom_robots'] ),
'robotsMeta' => ! empty( $this->data['titles']['homepage_robots'] ) ? $this->data['titles']['homepage_robots'] : null,
'socialDescription' => ! empty( $this->data['titles']['homepage_facebook_description'] ) ? $this->data['titles']['homepage_facebook_description'] : null,
Expand Down

0 comments on commit 73b86d3

Please sign in to comment.