X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=perl%2FSesse%2Fpr0n%2FCommon.pm;h=d2dcd7da04f61fe2e3347cce9223c380d324c57e;hb=0c4613d6b310d6dcd8e0035bc26abce3bbd97a08;hp=eff6fc13ecb991196a64fb8ea695708f1cf6d66b;hpb=3312d6e7db5fc3ff299ac8a6f916b352c57af185;p=pr0n diff --git a/perl/Sesse/pr0n/Common.pm b/perl/Sesse/pr0n/Common.pm index eff6fc1..d2dcd7d 100644 --- a/perl/Sesse/pr0n/Common.pm +++ b/perl/Sesse/pr0n/Common.pm @@ -265,9 +265,11 @@ sub update_image_info { $model =~ s/^\s*//; $model =~ s/\s*$//; + $model = undef if (length($model) == 0); $lens =~ s/^\s*//; $lens =~ s/\s*$//; + $lens = undef if (length($lens) == 0); # Now update the main table with the information we've got $dbh->do('UPDATE images SET width=?, height=?, date=?, model=?, lens=? WHERE id=?',