added after_action statements. Fixes #25
modified post_params. Fixes #26
added publish method to model. Fixes #27
added several methods to user model. Fixes #28
cleaned up the file to improve readability