Submit ham that is incorrectly tagged as spam.

Using this function will make you a good citizen as it helps Akismet to learn from its mistakes.  This will improve the service for everybody.
6697
public function submitHam()
    {
        $this->sendRequest($this->getQueryString(), $this->wordPressAPIKey . '.' . $this->akismetServer, '/' . $this->akismetVersion . '/submit-ham');
    }
704926
def spam(self, msg, *args, **kw):
        """"""
        if self.isEnabledFor(SPAM):
            self._log(SPAM, msg, args, **kw)
1290542
function action_submit ($param = null)
  {
    if (!isset($this->model))
      throw new FlashMessageException('Can\'t insert/update a NULL model.', FlashType::ERROR);

    throw new FlashMessageException('Can\'t automatically insert/update an object of type ' . gettype ($this->model),
      FlashType::ERROR);
  }
1371324
def handle(send, msg, args):
    
    session = args['db']
    matches = re.findall(r"\b(?<!-)(%s{2,16})(\+\+|--)" % args['config']['core']['nickregex'], msg)
    if not matches:
        return
    if args['type'] == 'privmsg':
        send('Hey, no points in private messages!')
        return
    for match in matches:
        # limit to 5 score changes per minute
        if args['abuse'](args['nick'], 5, 'scores'):
            return
        name, direction = match[0].lower(), match[1]
        if direction == "++":
            score = 1
            if name == args['nick'].lower():
                send("%s: No self promotion! You lose 10 points." % args['nick'])
                score = -10
        else:
            score = -1
        row = session.query(Scores).filter(Scores.nick == name).first()
        if row is None:
            session.add(Scores(score=score, nick=name))
            session.commit()
        else:
            row.score += score
            session.commit()
519474
def submit
      submit!
    rescue Exception => e
      if e.respond_to?(:record)
        inherit_errors(e.record) unless e.record == self
        false
      else
        raise
      end
    end
1086157
function(params, stateData) {
          // Handle an error response from the OAuth server
          if (params.error) {
            authLogger.log("RedirectLoginService.finish(), error", params.error, params.error_description, params.error_uri);
            return $q.reject({
              error: params.error,
              error_description: params.error_description,
              error_uri: params.error_uri
            });
          }

          // Handle an access_token fragment response
          if (params.access_token) {
            return $q.when({
              token: params.access_token,
              ttl: params.expires_in,
              then: stateData.then,
              verified: stateData.verified
            });
          }

          // No token and no error is invalid
          return $q.reject({
            error: "invalid_request",
            error_description: "No API token returned"
          });
        }
707159
public function callbackSubmit()
    {
        // Get values from the submitted form
        $text       = $this->form->value("text");

        if (!$this->di->get('session')->has("user")) {
            $this->form->addOutput("Du behöver logga in för att kommentera.");
            return false;
        }

        if ($text == "") {
            $this->form->addOutput("Du skrev aldrig något. Skriv gärna något.");
            return false;
        }


        $user = $this->di->get('session')->get("user"); # get user name

        $post     = new Post($this->di->get("db"));
        $post->questionId = $this->questionId;
        $post->user       = $user;
        $post->text       = $text;
        $post->type       = "answer";
        $post->accepted   = "no";
        $post->save();

        $this->form->addOutput("Du skapade ett svar!");
        return true;
    }
108751
def message(self, bot, comm):
        
        super(KarmaAdv, self).message(bot, comm)

        # No directed karma giving or taking
        if not comm['directed'] and not comm['pm']:
            msg = comm['message'].strip().lower()
            # use the magic above
            words = self.regstr.findall(msg)
            # Do things to people
            karmas = self.modify_karma(words)
            # Notify the users they can't modify their own karma
            if comm['user'] in karmas.keys():
                if karmas[comm['user']] <= 0:
                    bot.reply(comm, "Don't be so hard on yourself.")
                else:
                    bot.reply(comm, "Tisk, tisk, no up'ing your own karma.")
            # Commit karma changes to the db
            self.update_db(comm["user"], karmas)
18851
public function callbackSubmit()
    {
        $id = $this->form->value("id");
        $this->di->get("userService")->deleteUser($id);
        $this->di->get("utils")->redirect("admin");
    }
382344
def reply(self, text):
        
        # pylint: disable=W0212
        response = self.reddit_session._add_comment(self.fullname, text)
        # pylint: enable=W0212
        urls = [self.reddit_session.config['inbox']]
        if isinstance(self, Comment):
            urls.append(self.submission._api_link)  # pylint: disable=W0212
        elif isinstance(self, Message):
            urls.append(self.reddit_session.config['sent'])
        self.reddit_session.evict(urls)
        return response
423561
def assist_with(submission)
      @rules
        .select { |it| it.matches?(submission) }
        .map { |it| it.message_for(submission.attemps_count) }
    end
344345
def actually_toggle_spammed t
    thread = t
    if t.has_label? :spam
      t.remove_label :spam
      add_or_unhide t.first
      UpdateManager.relay self, :unspammed, t.first
      lambda do
        thread.apply_label :spam
        self.hide_thread thread
        UpdateManager.relay self,:spammed, thread.first
      end
    else
      t.apply_label :spam
      hide_thread t
      UpdateManager.relay self, :spammed, t.first
      lambda do
        thread.remove_label :spam
        add_or_unhide thread.first
        UpdateManager.relay self,:unspammed, thread.first
      end
    end
  end
380958
function send() {
		// Check form for errors
		if(!$("#transaction").val()) return alert('Missing parameter !');

		// Send
		nem.com.requests.transaction.announce(endpoint, $("#transaction").val()).then(function(res) {
			// If code >= 2, it's an error
			if (res.code >= 2) {
				alert(res.message);
			} else {
				alert(res.message);
			}
		}, function(err) {
			alert(err);
		})
	}
1209094
def process_request(self, request):
        """"""
        
        if COOKIE_KEY in request.COOKIES and \
            request.COOKIES[COOKIE_KEY] == COOKIE_SPAM:
                # Is a known spammer.
                response = HttpResponse("")
                # We do not reveal why it has been forbbiden:
                response.status_code = 404
                if DJANGOSPAM_LOG:
                    logger.log("SPAM REQUEST", request.method,
                       request.path_info,
                       request.META.get("HTTP_USER_AGENT", "undefined"))
                return response
        if DJANGOSPAM_LOG:
            logger.log("PASS REQUEST", request.method, request.path_info,
                       request.META.get("HTTP_USER_AGENT", "undefined"))
        return None
581383
protected function onFakeSubmit()
    {
        if ($this->request->isPost()) {

            if (! empty($this->formData['preview'])) {
                $this->addMessage($this->_('Preview updated'));
                return;
            }

            if (! empty($this->formData['sendtest'])) {
                $this->mailer->setTo($this->formData['to']);

                // Make sure at least one template is set (for single language projects)
                $template   = reset($this->formData['gctt']);
                $languageId = key($this->formData['gctt']);
                if ($this->formData['send_language']) {
                    foreach($this->formData['gctt'] as $languageId => $templateLanguage) {
                        // Find the current template (for multi language projects)
                        if ($templateLanguage['gctt_lang'] == $this->formData['send_language']) {
                            $template = $templateLanguage;
                        }
                    }
                }

                // \MUtil_Echo::track($this->formData);
                $errors = false;
                if (! $template['gctt_subject']) {
                    $this->addMessage(sprintf(
                            $this->_('Subject required for %s part.'),
                            strtoupper($template['gctt_lang'])
                            ));
                    $errors = true;
                }
                if (! $template['gctt_body']) {
                    $this->addMessage(sprintf(
                            $this->_('Body required for %s part.'),
                            strtoupper($template['gctt_lang']))
                            );
                    $errors = true;
                }

                if ($errors) {
                   return;
                }

                $this->mailer->setFrom($this->formData['from']);
                $this->mailer->setSubject($template['gctt_subject']);
                $this->mailer->setBody($template['gctt_body'], 'Bbcode');
                $this->mailer->setTemplateId($this->formData['gct_id_template']);
                $this->mailer->send();

                $this->addMessage(sprintf($this->_('Test mail sent to %s'), $this->formData['to']));
            }
        }
    }
1319860
function correctReply(reply, msg) {
  if (!_.isPlainObject(reply)) {
    reply = { "output": reply }
  }
  // autofill if not already exist
  reply["to"] = reply["to"] || msg["from"]
  reply["from"] = reply["from"] || ioid
  reply["hash"] = reply["hash"] || msg["hash"]
  return reply
}
523344
def complain(self, id, is_spam):
        
        r = self.request('post', 'http://cleanweb-api.yandex.ru/1.0/complain',
                         data={'id': id, 'spamtype': 'spam' if is_spam else 'ham'})
        return True