app/Http/Controllers/TheBlog/CategoryController.php
/**
     * Update the specified resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @param  \App\Models\Category  $category
     * @return \Illuminate\Http\Response
     */
Update the specified resource in storage.
Update the specified resource in storage .
public function update(UpdateCategoryRequest $request, $id)
    {
        $category = Category::findOrFail($id);
        $category->update( $request->except('_method') );
        return $this->sendResponse(new CategoryResource($category), 'Category updated successfully.');
    }
public function update ( UpdateCategoryRequest $ request , $ id ) { $ category = Category :: findOrFail ( $ id ) ; $ category -> update ( $ request -> except ( '_method' ) ) ; return $ this -> sendResponse ( new CategoryResource ( $ category ) , 'Category updated successfully.' ) ; }
Update the specified resource in storage.
Update the specified resource in storage .
//  return ($id);