Skip to content

Commit

Permalink
Slight optimizaton. Just trying to keep what the database does down to a
Browse files Browse the repository at this point in the history
minimum.
  • Loading branch information
theory committed Mar 11, 2003
1 parent 6decaa8 commit 7fd3c15
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions lib/Bric/Util/Coll/Site.pm
Expand Up @@ -8,15 +8,15 @@ Bric::Biz::Site objects.
=head1 VERSION
$Revision: 1.1.2.2 $
$Revision: 1.1.2.3 $
=cut

our $VERSION = (qw$Revision: 1.1.2.2 $ )[-1];
our $VERSION = (qw$Revision: 1.1.2.3 $ )[-1];

=head1 DATE
$Date: 2003-03-11 22:50:34 $
$Date: 2003-03-11 23:09:54 $
=head1 SYNOPSIS
Expand Down Expand Up @@ -190,14 +190,13 @@ sub save {
foreach my $site (@$new_objs) {
#insert into element__site mapping
my $sel = prepare_c( qq {
SELECT element__id, site__id
SELECT 1
FROM element__site
WHERE element__id = ? AND
site__id = ?
},undef, DEBUG);
execute($sel, $element_id, $site->get_id);
my $state = fetch($sel);
if ($state) {
}, undef, DEBUG);
my $state = col_aref($sel, $element_id, $site->get_id);
if (@$state) {
my $upd = prepare_c( qq {
UPDATE element__site
SET active = 1
Expand Down

0 comments on commit 7fd3c15

Please sign in to comment.