backend/app/controllers/lists_controller.rb
# Add before_action filter to show update and destroy 
Add before_action filter to show update and destroy
Add before_action filter to show update and destroy
def update
        @list = List.find_by(id: params[:id])
        if @list.update(list_params)
            render json: @list.as_json(include: {list_items: {only:[:content]}}) 
        else 
            render json: @list.errors, status: :unprocessable_entity
        end
    end
def update @list = List . find_by ( id : params [ :id ] ) if @list . update ( list_params ) render json : @list . as_json ( include : { list_items : { only : [ :content ] } } ) else render json : @list . errors , status : :unprocessable_entity end end
Add before_action filter to show update and destroy
Add before_action filter to show update and destroy