diff --git a/functions.php b/functions.php index 1f45cc1..9d54f38 100644 --- a/functions.php +++ b/functions.php @@ -73,9 +73,9 @@ function makeThumb($item = "") { $didwrite = file_put_contents($outfile, $imgdata); if ( !$didwrite ) return false; } elseif ( substr($comic, -3) == "cbr" ) { - $rar_file = rar_open($comic); + $rar_file = RarArchive::open($comic); if ( $rar_file === false ) { return false; } - $entries = rar_list($rar_file); + $entries = $rar_file->getEntries(); $lowest = "~"; foreach ( $entries as $entry ) { $imgname = $entry->getName(); @@ -89,7 +89,7 @@ function makeThumb($item = "") { } } } - rar_close($rar_file); + $rar_file->close(); } else { return false; }