X-Git-Url: http://git.cyclocoop.org/?a=blobdiff_plain;f=img_auth.php;h=44ef0a16627dff7693cb691af3513c28b08c7f05;hb=d3e023d11064a91c2478ef8dec8fa39d15d6bdfc;hp=6e45e4eba5a63af69742d7fa31635f81f8b5d33d;hpb=786524a94a5dd8f34c10b183bc59c91e2ad96589;p=lhc%2Fweb%2Fwiklou.git diff --git a/img_auth.php b/img_auth.php index 6e45e4eba5..44ef0a1662 100644 --- a/img_auth.php +++ b/img_auth.php @@ -39,6 +39,7 @@ */ define( 'MW_NO_OUTPUT_COMPRESSION', 1 ); +define( 'MW_ENTRY_POINT', 'img_auth' ); require __DIR__ . '/includes/WebStart.php'; # Set action base paths so that WebRequest::getPathInfo() @@ -96,8 +97,10 @@ function wfImageAuthMain() { } if ( $be->fileExists( [ 'src' => $filename ] ) ) { wfDebugLog( 'img_auth', "Streaming `" . $filename . "`." ); - $be->streamFile( [ 'src' => $filename ], - [ 'Cache-Control: private', 'Vary: Cookie' ] ); + $be->streamFile( [ + 'src' => $filename, + 'headers' => [ 'Cache-Control: private', 'Vary: Cookie' ] + ] ); } else { wfForbidden( 'img-auth-accessdenied', 'img-auth-nofile', $path ); }