Skip to content

Commit e9b1eae

Browse files
committed
Merge branch 'master' into jquery-ui
2 parents d705219 + c380e3b commit e9b1eae

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

server/php/upload.class.php

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22
/*
3-
* jQuery File Upload Plugin PHP Class 5.18.6
3+
* jQuery File Upload Plugin PHP Class 5.18.7
44
* https://github.com/blueimp/jQuery-File-Upload
55
*
66
* Copyright 2010, Sebastian Tschan
@@ -53,6 +53,7 @@ function __construct($options = null, $initialize = true) {
5353
'GET',
5454
'POST',
5555
'PUT',
56+
'PATCH',
5657
'DELETE'
5758
),
5859
'access_control_allow_headers' => array(
@@ -123,6 +124,8 @@ protected function initialize() {
123124
case 'GET':
124125
$this->get();
125126
break;
127+
case 'PATCH':
128+
case 'PUT':
126129
case 'POST':
127130
$this->post();
128131
break;
@@ -458,16 +461,16 @@ protected function orient_image($file_path) {
458461
$image = @imagecreatefromjpeg($file_path);
459462
switch ($orientation) {
460463
case 3:
461-
$image = @imagerotate($image, 180, 0);
462-
break;
464+
$image = @imagerotate($image, 180, 0);
465+
break;
463466
case 6:
464-
$image = @imagerotate($image, 270, 0);
465-
break;
467+
$image = @imagerotate($image, 270, 0);
468+
break;
466469
case 8:
467-
$image = @imagerotate($image, 90, 0);
468-
break;
470+
$image = @imagerotate($image, 90, 0);
471+
break;
469472
default:
470-
return false;
473+
return false;
471474
}
472475
$success = imagejpeg($image, $file_path);
473476
// Free up memory (imagedestroy does not delete files):

0 commit comments

Comments
 (0)