aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfrancis <francis>2009-07-17 14:04:34 +0000
committerfrancis <francis>2009-07-17 14:04:34 +0000
commitee0b55e7f3c6664e16dec8131925c0480f920a98 (patch)
treefd0064126d7a94f4e0af10842cea3e9f22cf7297
parent78692e3be74dbd7d2373859b2c0f9c80f2d61563 (diff)
In Passenger, the directory path is relative, so with the chdir need to just use current directory
in call to tempfile.
-rw-r--r--app/models/incoming_message.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/incoming_message.rb b/app/models/incoming_message.rb
index 5405ef180..d8aaeabe7 100644
--- a/app/models/incoming_message.rb
+++ b/app/models/incoming_message.rb
@@ -19,7 +19,7 @@
# Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved.
# Email: francis@mysociety.org; WWW: http://www.mysociety.org/
#
-# $Id: incoming_message.rb,v 1.209 2009-07-16 16:36:01 francis Exp $
+# $Id: incoming_message.rb,v 1.210 2009-07-17 14:04:34 francis Exp $
# TODO
# Move some of the (e.g. quoting) functions here into rblib, as they feel
@@ -284,7 +284,7 @@ class FOIAttachment
html = nil
Dir.chdir(dir) do
- tempfile = Tempfile.new('foiextract', dir)
+ tempfile = Tempfile.new('foiextract', '.')
tempfile.print self.body
tempfile.flush