original_string: public function show($id = null)
      {
          // Check the ID
          if (!isset($id)) {
              throw new \InvalidArgumentException('Undefined ID', 400);
          }
  
          // Get record
          $item = $this->model->find($id);
  
          // Abort if the record is not found
          if (!$item) {
              throw new \Exception('Element not found', 404);
          }
  
          // Return response
          return [
              'success' => true,
              'data' => $item
          ];
      }
code: public function show($id = null)
      {
          // Check the ID
          if (!isset($id)) {
              throw new \InvalidArgumentException('Undefined ID', 400);
          }
  
          // Get record
          $item = $this->model->find($id);
  
          // Abort if the record is not found
          if (!$item) {
              throw new \Exception('Element not found', 404);
          }
  
          // Return response
          return [
              'success' => true,
              'data' => $item
          ];
      }
code_tokens: public function show ( $ id = null ) { // Check the ID if ( ! isset ( $ id ) ) { throw new \ InvalidArgumentException ( 'Undefined ID' , 400 ) ; } // Get record $ item = $ this -> model -> find ( $ id ) ; // Abort if the record is not found if ( ! $ item ) { throw new \ Exception ( 'Element not found' , 404 ) ; } // Return response return [ 'success' => true , 'data' => $ item ] ; }
docstring: Display the specified resource
  
  @param array $id Resource ID
  @return array Response
docstring_tokens: Display the specified resource