title: How to abort in RedBean's update hook
body: <p>I have to do some validation in my Model and then abort if something went wrong. In a simplified version, it would look like this:</p>
  
  <pre><code>class Model extends RedBean_SimpleModel
  {
      public function update()
      {
          if(method_exists($this, 'validate') and ! $this-&gt;validate())
              $this-&gt;abort(); // made-up method
      }
  }
  </code></pre>
  
  <p>The thing is this <code>abort</code> method (or similar) doesn't seem to exist. The docs suggests to do it with Exceptions but I wanted the proccess to be more transparent. I couldn't catch the exception inside the Model code (to avoid repetition, since i already know what to do with the errors).</p>
  
  <p>A solution I found <a href="https://stackoverflow.com/questions/10325720/validation-in-redbean-php">here</a> was to open a transaction and then rollback on errors. But I really don't want this kind of overhead. Any thougths?</p>