original_string: public function getBrickBySlug($slug)
      {
          $bricks = $this->repository->bricks;
          foreach ($bricks as $brick) {
              if ($brick->slug == $slug) {
                  return $brick;
              }
          }
  
          return null;
      }
code: public function getBrickBySlug($slug)
      {
          $bricks = $this->repository->bricks;
          foreach ($bricks as $brick) {
              if ($brick->slug == $slug) {
                  return $brick;
              }
          }
  
          return null;
      }
code_tokens: public function getBrickBySlug ( $ slug ) { $ bricks = $ this -> repository -> bricks ; foreach ( $ bricks as $ brick ) { if ( $ brick -> slug == $ slug ) { return $ brick ; } } return null ; }
docstring: Get a brick by its slug
  
  @param $slug
  
  @return \stdClass
docstring_tokens: Get a brick by its slug