public function saveLibrary($library) {
    $dest = $this->path . '/libraries/' . \H5PCore::libraryToString($library, TRUE);

    // Make sure destination dir doesn't exist
    \H5PCore::deleteFileTree($dest);

    // Move library folder
    self::copyFileTree($library['uploadDirectory'], $dest);
  }