From: Chris W. <la...@us...> - 2004-11-25 03:55:46
|
Update of /cvsroot/openinteract/OpenInteract2/extra_packages/delicious_tags/OpenInteract2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13677/OpenInteract2 Modified Files: DeliciousTaggableObject.pm Log Message: ensure the URL we store is NOT contextualized Index: DeliciousTaggableObject.pm =================================================================== RCS file: /cvsroot/openinteract/OpenInteract2/extra_packages/delicious_tags/OpenInteract2/DeliciousTaggableObject.pm,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** DeliciousTaggableObject.pm 25 Nov 2004 03:14:04 -0000 1.4 --- DeliciousTaggableObject.pm 25 Nov 2004 03:55:31 -0000 1.5 *************** *** 4,10 **** --- 4,12 ---- use strict; + use OpenInteract2::URL; sub c_add_tags { my ( $class, $object_type, $object_id, $url, $name, @tags ) = @_; + $url = OpenInteract2::URL->strip_deployment_context( $url ); require OpenInteract2::DeliciousTag; return OpenInteract2::DeliciousTag *************** *** 39,42 **** --- 41,51 ---- my ( $object, @tags ) = @_; my $info = $object->object_description; + + # We want to remove any deployment descriptor from the front -- + # URLs are stored non-contextualized so things won't get hinky if + # you need to relocate + + $info->{url} = OpenInteract2::URL->strip_deployment_context( $info->{url} ); + return __PACKAGE__->c_add_tags( $info->{name}, $info->{object_id}, $info->{url}, $info->{title}, @tags ); |