Skip to content

Commit

Permalink
fix #7 broken images and empty files being sent
Browse files Browse the repository at this point in the history
  • Loading branch information
joshp23 committed Mar 12, 2021
1 parent 478229c commit ed16ad7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions usrv/assets/srv.php
Expand Up @@ -134,6 +134,8 @@
header('Content-type: ' . $ctype); // send the correct headers
header('Expires: 0'); // .
header('Content-Length: ' . filesize($file)); // .
ob_clean(); // .
flush(); // .
readfile($file); // with the file data
exit;
?>

1 comment on commit ed16ad7

@joshp23
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixes #7 and will hopefully fix joshp23/YOURLS-IQRCodes#41 and joshp23/YOURLS-Snapshot#13

Please sign in to comment.