mirror of
https://github.com/OpenNebula/one.git
synced 2026-11-19 11:22:55 +09:00
bug #2522: Fix rackinput check when uploading files from passenger
This commit is contained in:
1 parent
84e089d598
commit
fb58250c5b
1 file changed
+1
-1
@@ -417,7 +417,7 @@ post '/upload'do
|
||||
|
||||
if (rackinput.class == Tempfile)
|
||||
tmpfile = rackinput
|
||||
elsif (rackinput.class == StringIO || rackinput.class == PhusionPassenger::Utils::RewindableInput)
|
||||
elsif rackinput.respond_to?('read')
|
||||
tmpfile = Tempfile.open('sunstone-upload')
|
||||
tmpfile.write rackinput.read
|
||||
tmpfile.flush
|
||||
|
||||
Reference in new issue
Block a user