Do not encrypt None values

Currently, a value of None will be interpreted as the string 'None' and stored encrypted in the database. This means that when you read it back, you get the string 'None' instead of an actual None.

This pull request fixes that by skipping encryption for None values.