diff --git a/app/controllers/api/v1/posts_controller.rb b/app/controllers/api/v1/posts_controller.rb index 69993a8..f7ac88b 100644 --- a/app/controllers/api/v1/posts_controller.rb +++ b/app/controllers/api/v1/posts_controller.rb @@ -16,6 +16,11 @@ def show render json: @post end + # GET /api/v1/posts/1 + def show_v2 + render json: @post + end + # POST /api/v1/posts def create @post = Post.new(post_params)