File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -148,6 +148,10 @@ function wp_api_v2_menus_get_menu_items( $id ) {
148148 if (isset ($ item ->thumbnail_id ) && $ item ->thumbnail_id ) {
149149 $ item ->thumbnail_src = wp_get_attachment_image_url (intval ($ item ->thumbnail_id ), 'post-thumbnail ' );
150150 }
151+ if (isset ($ item ->thumbnail_hover_id ) && $ item ->thumbnail_hover_id ) {
152+ $ item ->thumbnail_hover_src = wp_get_attachment_image_url (intval ($ item ->thumbnail_hover_id ), 'post-thumbnail ' );
153+ }
154+
151155 } else if ($ item ->type == 'taxonomy ' ) {
152156 $ cat = get_term ($ item ->object_id );
153157 $ item ->slug = $ cat ->slug ;
@@ -163,6 +167,9 @@ function wp_api_v2_menus_get_menu_items( $id ) {
163167 if (isset ($ item ->thumbnail_id ) && $ item ->thumbnail_id ) {
164168 $ item ->thumbnail_src = wp_get_attachment_image_url (intval ($ item ->thumbnail_id ), 'post-thumbnail ' );
165169 }
170+ if (isset ($ item ->thumbnail_hover_id ) && $ item ->thumbnail_hover_id ) {
171+ $ item ->thumbnail_hover_src = wp_get_attachment_image_url (intval ($ item ->thumbnail_hover_id ), 'post-thumbnail ' );
172+ }
166173
167174 array_push ( $ child_items , $ item );
168175 unset( $ menu_items [ $ key ] );
You can’t perform that action at this time.
0 commit comments