Right, but this code assures that your code will never run on our installs.  And we will have the problem any time a user is not using pinserver to protect their private files.

AKA when os_files_private_pinserver == 0
https://github.com/openscholar/openscholar/blob/71fdc967455718acc24d9405226c5f5aa8398daa/openscholar/modules/harvard/os_pinserver_auth/includes/os_pinserver_auth_stream_wrapper.inc#L17