Skip to content

Commit

Permalink
Add support to retrieve selected header template part
Browse files Browse the repository at this point in the history
  • Loading branch information
arunshenoy99 committed Aug 27, 2024
1 parent 8d8531d commit 4913f36
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions includes/Services/FlowService.php
Original file line number Diff line number Diff line change
Expand Up @@ -439,4 +439,18 @@ public static function get_onboarding_coming_soon() {
$data = self::read_data_from_wp_option( false );
return isset( $data['data']['comingSoon'] ) ? $data['data']['comingSoon'] : null;
}

/**
* Retrieves the selected header template part.
*
* This function reads data from the WordPress options and returns the selected
* header template part if it exists. If the header template part is not set,
* it returns null.
*
* @return string|null The selected header template part or null if not set.
*/
public static function get_selected_header_template_part() {
$data = self::read_data_from_wp_option( false );
return ( ! empty( $data['data']['partHeader'] ) ) ? $data['data']['partHeader'] : null;
}
}

0 comments on commit 4913f36

Please sign in to comment.