@@ -53,7 +53,7 @@ function __construct($options = null, $initialize = true) {
53
53
'GET ' ,
54
54
'POST ' ,
55
55
'PUT ' ,
56
- 'PATCH ' ,
56
+ 'PATCH ' ,
57
57
'DELETE '
58
58
),
59
59
'access_control_allow_headers ' => array (
@@ -124,8 +124,8 @@ protected function initialize() {
124
124
case 'GET ' :
125
125
$ this ->get ();
126
126
break ;
127
- case 'PATCH ' :
128
- case 'PUT ' :
127
+ case 'PATCH ' :
128
+ case 'PUT ' :
129
129
case 'POST ' :
130
130
$ this ->post ();
131
131
break ;
@@ -461,16 +461,16 @@ protected function orient_image($file_path) {
461
461
$ image = @imagecreatefromjpeg ($ file_path );
462
462
switch ($ orientation ) {
463
463
case 3 :
464
- $ image = @imagerotate ($ image , 180 , 0 );
465
- break ;
464
+ $ image = @imagerotate ($ image , 180 , 0 );
465
+ break ;
466
466
case 6 :
467
- $ image = @imagerotate ($ image , 270 , 0 );
468
- break ;
467
+ $ image = @imagerotate ($ image , 270 , 0 );
468
+ break ;
469
469
case 8 :
470
- $ image = @imagerotate ($ image , 90 , 0 );
471
- break ;
470
+ $ image = @imagerotate ($ image , 90 , 0 );
471
+ break ;
472
472
default :
473
- return false ;
473
+ return false ;
474
474
}
475
475
$ success = imagejpeg ($ image , $ file_path );
476
476
// Free up memory (imagedestroy does not delete files):
@@ -540,17 +540,17 @@ protected function handle_file_upload($uploaded_file, $name, $size, $type, $erro
540
540
return $ file ;
541
541
}
542
542
543
- protected function readfile ($ file_path ) {
544
- return readfile ($ file_path );
545
- }
543
+ protected function readfile ($ file_path ) {
544
+ return readfile ($ file_path );
545
+ }
546
546
547
- protected function body ($ str ) {
548
- echo $ str ;
549
- }
550
-
551
- protected function header ($ str ) {
552
- header ($ str );
553
- }
547
+ protected function body ($ str ) {
548
+ echo $ str ;
549
+ }
550
+
551
+ protected function header ($ str ) {
552
+ header ($ str );
553
+ }
554
554
555
555
protected function generate_response ($ content , $ print_response = true ) {
556
556
if ($ print_response ) {
0 commit comments