Forum OpenACS Development: Re: File Storage: View vs. Download

Collapse
Posted by Malte Sussdorff on
While at it, any reasons to support "private" for file.vuh? I played around with it a little bit and could not get it to work and I'm wondering if we need this for files in the first place....

The check for item_id or revision_id looks like this:

set revision_id [content::item::get_best_revision -item_id $object_id]
if {$revision_id eq ""} {
    set revision_id $object_id
    set item_id [content::revision::item_id -revision_id $object_id]
} else {
    set item_id $object_id
}

if {$revision_id eq ""} {
    ns_returnnotfound
    ad_script_abort
}

Did I miss any real world example where I would end up stranded (where the file exists but the revision_id would be empty)?

Collapse
Posted by Malte Sussdorff on
Hopefully the last thought on this topic... image.vuh could call file.vuh after doing the special image checking? Or should we leave it serving the image on it's own. I'm wondering if we need this distinction (though you could then go as far and, if you answer you need private for files, if we just change the code in OpenACS to not call image, but file.vuh, but this is for a different discussion).