Updates in code

* DRYed out writing to db method (code is still not very DRY)
* Used new hash format
* Added options for `course_name` & `course_desc` to `write_to_cert`