title: How to use encryption in ydn-db database library?
body: <p>I am trying to implement setSecret to encrypt the values in indexeddb but get the error:</p>
  
  <p><strong>"unable to call method setSecret of undefined"</strong></p>
  
  <p>Code Below:</p>
  
  <pre><code> $(window).load(function () {
  
     //Database Schema
      var db_schema = {
      stores: [
          {
              name: "Employees",
          }
      ]
  }
  
  var secret = "Test";
  db.setSecret(secret); 
  
      db = new ydn.db.Storage('Database', db_schema);
  
  });
  </code></pre>
  
  <p>Following the <a href="http://dev.yathit.com/ydn-db/using/encryption.html" rel="nofollow">link</a>, but not sure where I'm going wrong any ideas:</p>
  
  <p>Anyone encrpyted there indexddb values before?</p>
  
  <p>Thanks</p>