code: public function isPostCheck($redirectUrl = null)
      {
          if ($this->getRequest()->isPost) {
              return true;
          }
          if (is_null($redirectUrl)) {
              return false;
          }
          $this->sendTerminalResponse($redirectUrl);
      }
docs: Checks if the current request is a POST and handles redirection
  @author Olawale Lawal <wale@cottacush.com>
  @param null $redirectUrl
  @return bool