Changeset 1115
- Timestamp:
- 12/01/08 12:01:08 (3 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
-
UnitTestContrib/test/unit/Fn_REVINFO.pm (modified) (1 diff)
-
core/lib/Foswiki.pm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/UnitTestContrib/test/unit/Fn_REVINFO.pm
r816 r1115 194 194 } 195 195 196 sub test_42 { 197 my $this = shift; 198 $this->{twiki}->{store}->saveTopic( 199 $this->{test_user_cuid}, 200 $this->{test_web}, "HappyPill", 201 " * Set ALLOWTOPICVIEW = CarlosCastenada\n"); 202 $this->{twiki}->finish(); 203 $this->{twiki} = new Foswiki(); 204 my $ui = $this->{twiki}->handleCommonTags( 205 '%REVINFO{topic="'.$this->{test_web}.'.HappyPill" format="$username $wikiname $wikiusername"}%', 206 $this->{test_web}, 'GlumDrop'); 207 $this->assert($ui =~ /No permission to view/); 208 } 209 196 210 # SMELL: need to test for other revs specified by the 'rev' parameter 197 211 -
trunk/core/lib/Foswiki.pm
r1090 r1115 3625 3625 my $rev = $params->{rev} || $cgiRev || ''; 3626 3626 3627 ( $web, $topic ) = $this->normalizeWebTopicName( $web, $topic ); 3628 if ($web ne $theWeb || $topic ne $theTopic) { 3629 unless ( 3630 $this->security->checkAccessPermission( 3631 'VIEW', $this->{user}, undef, undef, $topic, $web 3632 ) 3633 ) 3634 { 3635 return $this->inlineAlert( 'alerts', 'access_denied', $web, 3636 $topic ); 3637 } 3638 } 3639 3627 3640 return $this->renderer->renderRevisionInfo( $web, $topic, undef, $rev, 3628 3641 $format );
Note: See TracChangeset
for help on using the changeset viewer.
