public function getPagesMenu($menuName, $lang = NULL)
    {
//         $currentUser = $this->securityContext->getToken()->getUser();
//         if ($currentUser != 'anon.')
//         {
//             $roles = $currentUser->getRoles();
//         }
//         else
//         {
//             $roles = array();
//         }
        $pages = $this->doctrine->getRepository('FulgurioLightCMSBundle:PageMenu')->findPagesOfMenu($menuName, $lang);
        $availablePages = array();
        foreach ($pages as &$page)
        {
//             $pageAccesses = $page->getAccess();
//             if (empty($pageAccesses))
//             {
//                 $page->setAllowedChildren($this->doctrine->getRepository('FulgurioLightCMSBundle:Page')->getAllowedChildren($roles, $page));
                $availablePages[] = $page;
//             }
//             else if (is_object($currentUser))
//             {
//                 foreach ($pageAccesses as $pageAccess)
//                 {
//                     if ($currentUser->hasRole($pageAccess))
//                     {
//                         $page->setAllowedChildren($this->doctrine->getRepository('FulgurioLightCMSBundle:Page')->getAllowedChildren($roles, $page));
//                         $availablePages[] = $page;
//                         break;
//                     }
//                 }
//             }
        }
        return $availablePages;
    }