Skip to content
This repository has been archived by the owner on Jul 23, 2024. It is now read-only.

Replace depricated acf_get_term_post_id() function #191

Merged
merged 1 commit into from
Feb 5, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/class-config.php
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ protected function get_acf_field_value( $root, $acf_field, $format = false ) {

switch ( true ) {
case $root instanceof Term:
$id = acf_get_term_post_id( $root->taxonomyName, $root->term_id );
$id = 'term_' . $root->term_id;
break;
case $root instanceof Post:
$id = absint( $root->ID );
Expand All @@ -242,7 +242,7 @@ protected function get_acf_field_value( $root, $acf_field, $format = false ) {
$id = absint( $root->menuItemId );
break;
case $root instanceof Menu:
$id = acf_get_term_post_id( 'nav_menu', $root->menuId );
$id = 'term_' . $root->menuId;
break;
case $root instanceof User:
$id = 'user_' . absint( $root->userId );
Expand Down