def destroy
      respond_to do |format|
        if @post.update(is_deleted: true)
          format.json { render json: @post, status: 200 }
        else
          format.json { render json: @post.errors, status: :internal_server_error }
        end
      end
    end
def destroy
      respond_to do |format|
        if @post.update(is_deleted: true)
          format.json { render json: @post, status: 200 }
        else
          format.json { render json: @post.errors, status: :internal_server_error }
        end
      end
    end
DELETE /posts/1