updated todo and optimized show action and related query. redirected to home after creation/updating of author