'user_settings', //]); //jvbAdminMap(); $shops = jvbGetArtistShops(get_current_user_id()); if (empty($shops)) { echo '

I\'m not sure how you got here...

'; echo '

It doesn\'t look like you manage any shops, so nothing is showing up here.

'; } $nav = '

Your Shops:

'; echo $nav; $handler = JVB()->getContent('shop'); $i = 0; foreach ($shops as $shop) { $active = ($i=== 0) ? ' active' : ''; echo '
'; jvbRenderSections($handler, $shop->term_id, 'term', BASE.'shop', true); echo '
'; $i++; } echo ''; function jvbGetArtistShops($userID) { $owner = explode(',', get_user_meta($userID, BASE.'owner_of', true)); $manager = explode(',', get_user_meta($userID, BASE.'manager_of', true)); return array_unique(array_filter(array_merge($owner, $manager))); }