original_string: public function getOrFind($id, $published = true)
      {
          $node = $this->get($id);
  
          if (is_null($node))
          {
              $node = $published ?
                  PublishedNode::find($id) :
                  Node::find($id);
  
              $this->put($id, $node);
          }
  
          return $node;
      }
code: public function getOrFind($id, $published = true)
      {
          $node = $this->get($id);
  
          if (is_null($node))
          {
              $node = $published ?
                  PublishedNode::find($id) :
                  Node::find($id);
  
              $this->put($id, $node);
          }
  
          return $node;
      }
code_tokens: public function getOrFind ( $ id , $ published = true ) { $ node = $ this -> get ( $ id ) ; if ( is_null ( $ node ) ) { $ node = $ published ? PublishedNode :: find ( $ id ) : Node :: find ( $ id ) ; $ this -> put ( $ id , $ node ) ; } return $ node ; }
docstring: Gets or finds the node and sets by id
  
  @param int $id
  @param bool $published
  @return Node
docstring_tokens: Gets or finds the node and sets by id