[interchange-cvs] interchange - heins modified dist/lib/UI/usertag/list_databases.tag
interchange-core@interchange.redhat.com
interchange-core@interchange.redhat.com
Mon Oct 1 13:58:01 2001
User: heins
Date: 2001-10-01 17:57:07 GMT
Modified: dist/lib/UI/usertag Tag: STABLE_4_8-branch
Modified: list_databases.tag
Log:
* Prevent limitations on database show for superuser, found by
Ed LaFrance.
A different fix using common code from Primitive.pm will be
made for 4.9 -- the $::Values->{ui_tables_to_hide} stuff is meaningless
and ancient.
Revision Changes Path
No revision
No revision
2.0.2.1 +16 -14 interchange/dist/lib/UI/usertag/list_databases.tag
rev 2.0.2.1, prev_rev 2.0
Index: list_databases.tag
===================================================================
RCS file: /anon_cvs/repository/interchange/dist/lib/UI/usertag/list_databases.tag,v
retrieving revision 2.0
retrieving revision 2.0.2.1
diff -u -r2.0 -r2.0.2.1
--- list_databases.tag 2001/07/18 02:22:15 2.0
+++ list_databases.tag 2001/10/01 17:57:07 2.0.2.1
@@ -10,23 +10,25 @@
@dbs = sort keys %$d;
my @outdb;
my $record = ui_acl_enabled();
- undef $record
- unless ref($record)
- and $record->{yes_tables} || $record->{no_tables};
+ unless ($record->{super}) {
+ undef $record
+ unless ref($record)
+ and $record->{yes_tables} || $record->{no_tables};
- for(@dbs) {
- next if $::Values->{ui_tables_to_hide} =~ /\b$_\b/;
- if($record) {
- next if $record->{no_tables}
- and ui_check_acl($_, $record->{no_tables});
- my $check = "$_$extended";
- next if $record->{yes_tables}
- and ! ui_check_acl($check, $record->{yes_tables});
+ for(@dbs) {
+ next if $::Values->{ui_tables_to_hide} =~ /\b$_\b/;
+ if($record) {
+ next if $record->{no_tables}
+ and ui_check_acl($_, $record->{no_tables});
+ my $check = "$_$extended";
+ next if $record->{yes_tables}
+ and ! ui_check_acl($check, $record->{yes_tables});
+ }
+ push @outdb, $_;
}
- push @outdb, $_;
- }
- @dbs = $nohide ? (@dbs) : (@outdb);
+ @dbs = $nohide ? (@dbs) : (@outdb);
+ }
my $string = join " ", grep /\S/, @dbs;
return $string;