title: 'bytes' object has no attribute 'encode'
body: <p>I'm trying to store salt and hashed password before inserting each document into a collection. But on encoding the salt and password, it shows the following error:</p>
  
  <pre><code> line 26, in before_insert
   document['salt'] = bcrypt.gensalt().encode('utf-8')
  
  AttributeError: 'bytes' object has no attribute 'encode'
  </code></pre>
  
  <p>This is my code: </p>
  
  <pre><code>def before_insert(documents):
      for document in documents:
          document['salt'] = bcrypt.gensalt().encode('utf-8')
          password = document['password'].encode('utf-8')
          document['password'] = bcrypt.hashpw(password, document['salt'])
  </code></pre>
  
  <p>I'm using eve framework in virtualenv with python 3.4</p>