$nws = array();
$nb = 0;
foreach ($this->networks as $id => $nw) {
if (($flags & Profile::NETWORKING_WEB) && $nw['network_type']->hasFlag('web') ||
($flags & Profile::NETWORKING_IM) && $nw['network_type']->hasFlag('im') ||
($flags & Profile::NETWORKING_SOCIAL) && $nw['network_type']->hasFlag('social') ||
$nws = array();
$nb = 0;
foreach ($this->networks as $id => $nw) {
if (($flags & Profile::NETWORKING_WEB) && $nw['network_type']->hasFlag('web') ||
($flags & Profile::NETWORKING_IM) && $nw['network_type']->hasFlag('im') ||
($flags & Profile::NETWORKING_SOCIAL) && $nw['network_type']->hasFlag('social') ||