original_string: public function progress_bar(array $items) {
          foreach ($items as &$item) {
              $text = $item['text'];
              unset($item['text']);
              if (array_key_exists('link', $item)) {
                  $link = $item['link'];
                  unset($item['link']);
                  $item = html_writer::link($link, $text, $item);
              } else {
                  $item = html_writer::tag('span', $text, $item);
              }
          }
          return html_writer::tag('div', join(get_separator(), $items), array('class' => 'backup_progress clearfix'));
      }
code: public function progress_bar(array $items) {
          foreach ($items as &$item) {
              $text = $item['text'];
              unset($item['text']);
              if (array_key_exists('link', $item)) {
                  $link = $item['link'];
                  unset($item['link']);
                  $item = html_writer::link($link, $text, $item);
              } else {
                  $item = html_writer::tag('span', $text, $item);
              }
          }
          return html_writer::tag('div', join(get_separator(), $items), array('class' => 'backup_progress clearfix'));
      }
code_tokens: public function progress_bar ( array $ items ) { foreach ( $ items as & $ item ) { $ text = $ item [ 'text' ] ; unset ( $ item [ 'text' ] ) ; if ( array_key_exists ( 'link' , $ item ) ) { $ link = $ item [ 'link' ] ; unset ( $ item [ 'link' ] ) ; $ item = html_writer :: link ( $ link , $ text , $ item ) ; } else { $ item = html_writer :: tag ( 'span' , $ text , $ item ) ; } } return html_writer :: tag ( 'div' , join ( get_separator ( ) , $ items ) , array ( 'class' => 'backup_progress clearfix' ) ) ; }
docstring: Renderers a progress bar for the backup or restore given the items that make it up.
  
  @param array $items An array of items
  @return string
docstring_tokens: Renderers a progress bar for the backup or restore given the items that make it up .