code: public function update(UpdateRequest $request)
      {
          $data = $request->all();
  
          $model = $this->repository->getSettingByKey($data['key']);
  
          $model->update( $data );
  
          \Cache::tags('response')->flush();
  
          return $this->successJsonResponse();
      }
docs: Update
  
  @param UpdateRequest $request
  
  @return \Illuminate\Http\JsonResponse