Refactor PublicUploadsController to remove helper

This helper is going to be factored out of all the attachment
controllers eventually.