Added authentication, admin actions, voting funcitonality and sped up post index view

I'm not sure what's the reason for adding this at all but this is probably not doing what you expect. 

The `reset_flash` method is not doing anything, it's only setting a local variable `flash` and then discarding it. What you probably wanted to write is `self.flash = {}` which would then call the `flash=` method of the controller instance. That would be wrong and likely cause other issues though.

The `flash` "hash" does not need to be reset since that's exactly it's normal behavior. From the docs: 

> The flash provides a way to pass temporary objects between actions. Anything you place in the flash will be exposed to the very next action and then cleared out. [1]

If you want to store something that is valid only for the current action, use `flash.now[:message] = "Message"`. From the docs:

> Sets a flash that will not be available to the next action, only to the current. [2]

[1] http://api.rubyonrails.org/classes/ActionDispatch/Flash.html
[2] http://api.rubyonrails.org/classes/ActionDispatch/Flash/FlashHash.html#method-i-now