/**
  * Gets the array of the local lessons & series.
  *
  * @return array
  */
 public function getAllLessons()
 {
     $array = [];
     $array['lessons'] = $this->getLessons(true);
     $array['series'] = $this->getSeries(true);
     Downloader::$currentLessonNumber = count($array['lessons']);
     return $array;
 }
 /**
  * Grabs all lessons & series from the website.
  */
 public function getAllLessons()
 {
     $array = [];
     $html = $this->getAllPage();
     Parser::getAllLessons($html, $array);
     while ($nextPage = Parser::hasNextPage($html)) {
         $html = $this->client->get($nextPage, ['verify' => false])->getBody()->getContents();
         Parser::getAllLessons($html, $array);
     }
     Downloader::$currentLessonNumber = count($array['lessons']);
     return $array;
 }