original_string: public function getLoan()
      {
          $data = $this->client->getJSON($this->url('/loans'));
  
          if ($data->total_record_count == 1) {
              return Loan::make(
                  $this->client,
                  User::make($this->client, $data->item_loan[0]->user_id),
                  $data->item_loan[0]->loan_id
              )->init($data->item_loan[0]);
          }
      }
code: public function getLoan()
      {
          $data = $this->client->getJSON($this->url('/loans'));
  
          if ($data->total_record_count == 1) {
              return Loan::make(
                  $this->client,
                  User::make($this->client, $data->item_loan[0]->user_id),
                  $data->item_loan[0]->loan_id
              )->init($data->item_loan[0]);
          }
      }
code_tokens: public function getLoan ( ) { $ data = $ this -> client -> getJSON ( $ this -> url ( '/loans' ) ) ; if ( $ data -> total_record_count == 1 ) { return Loan :: make ( $ this -> client , User :: make ( $ this -> client , $ data -> item_loan [ 0 ] -> user_id ) , $ data -> item_loan [ 0 ] -> loan_id ) -> init ( $ data -> item_loan [ 0 ] ) ; } }
docstring: Get the current loan as a Loan object, or null if the item is not loaned out.
  
  @returns Loan|null
docstring_tokens: Get the current loan as a Loan object or null if the item is not loaned out .