Пример #1
0
 /**
  * Get member if exists
  *
  * @return Sppc_Member
  */
 public function getMember()
 {
     if (is_null($this->_member)) {
         $memberModel = new Sppc_MemberModel();
         $rowset = $memberModel->find($this->getId());
         if (count($rowset)) {
             $this->_member = $rowset->current();
         } else {
             $this->_member = false;
         }
     }
     if ($this->_member === false) {
         return null;
     }
     return $this->_member;
 }