From 17cdae613d339d31aacabfd232fdd9f67bea6c3a Mon Sep 17 00:00:00 2001 From: ilotterytea Date: Wed, 25 Jun 2025 00:13:02 +0500 Subject: feat: custom swf parser because swftools is obsolete --- lib/thumbnails.php | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'lib/thumbnails.php') diff --git a/lib/thumbnails.php b/lib/thumbnails.php index 5e99087..5afc775 100644 --- a/lib/thumbnails.php +++ b/lib/thumbnails.php @@ -10,15 +10,7 @@ function generate_image_thumbnail(string $src_path, string $dst_path, int $width $result_code = null; - if (str_ends_with($src_path, ".swf")) { - exec(command: "swfrender $input_path -o $output_path", result_code: $result_code); - if ($result_code != 0) { - return $result_code; - } - exec(command: "magick $output_path -resize {$width}x{$height} -loop 0 $output_path", result_code: $result_code); - } else { - exec(command: "magick $input_path -resize {$width}x{$height} -loop 0 $output_path", result_code: $result_code); - } + exec(command: "magick $input_path -resize {$width}x{$height} -loop 0 $output_path", result_code: $result_code); return $result_code; } -- cgit v1.2.3