original_string: protected function stripLinkBase($link)
      {
          // Trim baseURL
          $link = preg_replace('/^' . preg_quote(Director::baseURL(), '/') .'/', '', $link);
  
          // Trim link_base
          if ($linkBase = Config::inst()->get('DocumentationViewer', 'link_base')) {
              $link = preg_replace('/^' . preg_quote($linkBase, '/') .'\/?/', '', $link);
          }
  
          return $link;
      }
code: protected function stripLinkBase($link)
      {
          // Trim baseURL
          $link = preg_replace('/^' . preg_quote(Director::baseURL(), '/') .'/', '', $link);
  
          // Trim link_base
          if ($linkBase = Config::inst()->get('DocumentationViewer', 'link_base')) {
              $link = preg_replace('/^' . preg_quote($linkBase, '/') .'\/?/', '', $link);
          }
  
          return $link;
      }
code_tokens: protected function stripLinkBase ( $ link ) { // Trim baseURL $ link = preg_replace ( '/^' . preg_quote ( Director :: baseURL ( ) , '/' ) . '/' , '' , $ link ) ; // Trim link_base if ( $ linkBase = Config :: inst ( ) -> get ( 'DocumentationViewer' , 'link_base' ) ) { $ link = preg_replace ( '/^' . preg_quote ( $ linkBase , '/' ) . '\/?/' , '' , $ link ) ; } return $ link ; }
docstring: Remove the link_base from the start of a link
  
  @param  string $link
  @return string
docstring_tokens: Remove the link_base from the start of a link