/** * Count pending emails * * @return integer */ function countPending() { return IncomingMails::count(array('state > 0')); }