]> git.sesse.net Git - pr0n/blobdiff - perl/Sesse/pr0n/Common.pm
Fix indentation issues.
[pr0n] / perl / Sesse / pr0n / Common.pm
index 28a1989b1f5d8f8ef2dc04103b984249210c83af..52d6ee2f61544c5101dc52a83905b0a2a746b764 100644 (file)
@@ -32,7 +32,7 @@ BEGIN {
                require Sesse::pr0n::Config_local;
        };
 
-       $VERSION     = "v3.10";
+       $VERSION     = "v3.20";
        @ISA         = qw(Exporter);
        @EXPORT      = qw(&error &dberror);
        %EXPORT_TAGS = qw();
@@ -207,20 +207,20 @@ sub get_dbh {
 
 sub get_disk_location {
        my ($r, $id) = @_;
-        my $dir = POSIX::floor($id / 256);
+       my $dir = POSIX::floor($id / 256);
        return $Sesse::pr0n::Config::image_base . "images/$dir/$id.jpg";
 }
 
 sub get_cache_location {
        my ($id, $width, $height) = @_;
-        my $dir = POSIX::floor($id / 256);
+       my $dir = POSIX::floor($id / 256);
 
        return $Sesse::pr0n::Config::image_base . "cache/$dir/$id-$width-$height-nobox.jpg";
 }
 
 sub get_infobox_cache_location {
        my ($id, $width, $height, $dpr) = @_;
-        my $dir = POSIX::floor($id / 256);
+       my $dir = POSIX::floor($id / 256);
 
        if ($dpr == 1) {
                return $Sesse::pr0n::Config::image_base . "cache/$dir/$id-$width-$height-box.png";
@@ -248,7 +248,7 @@ sub ensure_disk_location_exists {
 
 sub get_mipmap_location {
        my ($r, $id, $width, $height) = @_;
-        my $dir = POSIX::floor($id / 256);
+       my $dir = POSIX::floor($id / 256);
 
        return $Sesse::pr0n::Config::image_base . "cache/$dir/$id-mipmap-$width-$height.jpg";
 }
@@ -616,7 +616,7 @@ sub ensure_cached {
                        my $sf = "1x1";
 
                        if ($xres != -1) {
-                               $cimg->Resize(width=>$nwidth, height=>$nheight, filter=>$filter, 'sampling-factor'=>$sf);
+                               $cimg->Resize(width=>$nwidth, height=>$nheight, filter=>$filter);
                        }
 
                        # Strip EXIF tags etc.