From: Simon Cozens <simon@simon-cozens.org>
Date: Mon, 2 Apr 2007 18:50:54 +0000 (+0000)
Subject: Make it all at least work.
X-Git-Tag: 1.2+svn20070808~14
X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=0df4ac395c035b6a2968fe64ca3f5dadd8ecbd39;p=memories.git

Make it all at least work.


git-svn-id: http://svn.simon-cozens.org/memories/trunk@54 041978f6-d955-411f-a9d7-1d8545c9c3c7
---

diff --git a/Memories/Photo.pm b/Memories/Photo.pm
index a922807..9e922f3 100644
--- a/Memories/Photo.pm
+++ b/Memories/Photo.pm
@@ -1,5 +1,5 @@
 package Memories::Photo;
-use Apache2::Upload;
+#use Apache2::Upload;
 use File::Basename;
 use File::Copy;
 use Archive::Any;
@@ -128,10 +128,10 @@ sub upload_raw {
     $filename =~ /\.(.*)$/;
     my $format = $1;
     # Put the file in place
+    my $photo = $self->upload_jpeg($r, $jpg, $offered_name);
     $photo->format($format);
     copy($filename, 
          Memories->config->{data_store}."/".$photo->id.".".$format);
-    my $photo = $self->upload_jpeg($r, $jpg, $offered_name);
     return $photo;
 }