public function actionActivate($code, $email)
 {
     $result = UserApi::activateCode($code, $email);
     if ($result == true) {
         $data = array();
         $user = UserApi::getUserByEmail($email);
         $user ? $data["user"] = $user->id : null;
         EmailApi::sendEmail($email, "REGISTRATION.SUCCESS", $data);
     }
     $this->render('activate', array('result' => $result));
 }