title: Dart exception when upgrading IndexedDB
body: <p>I get an exception when i try to upgrade my indexedDB database with a higher version then the browser currently has,
  but the funny part abort is that, it gets upgraded. Is this by design or have i done something wrong.</p>
  
  <p>I got very inspired from the dart sample Todo, so my code ended up looking like this.</p>
  
  <pre class="lang-dart prettyprint-override"><code>void open_db(String DB_name, int Version, String Store_Name){
    var request = window.indexedDB.open(DB_name, Version);
    request.on.success.add((e) =&gt; _onDbOpened(request.result));
    request.on.error.add((e) =&gt; print("Error opening db"));
    request.on.upgradeNeeded.add((e) =&gt; _onUpgradeNeeded(request.transaction, Store_Name));
  }
  
  void _onDbOpened(IDBDatabase db){
    _db = db;
    print("DB opened");
  }
  
  void _onUpgradeNeeded(IDBTransaction changeVersionTransaction, String Store_Name){
    changeVersionTransaction.on.error.add((e) =&gt; print("Error upgrading db"));
    changeVersionTransaction.on.complete.add((e) =&gt; print("Success upgrading db"));
    changeVersionTransaction.db.createObjectStore(Store_Name);
  }
  </code></pre>
  
  <p>When I run this with version=4 and the browser only have version=3, then it jumps to _onUpgradeNeeded as expected, but I get an IDBDatabaseException with message: "ConstraintError: DOM IDBDatabase Exception 4".</p>
  
  <p>So where is it I go wrong?</p>