Index: trunk/extensions/CodeReview/ui/CodeRevisionView.php |
— | — | @@ -288,14 +288,20 @@ |
289 | 289 | if ( $viewvc ) { |
290 | 290 | $rev = $this->mRev->getId(); |
291 | 291 | $prev = $rev - 1; |
292 | | - if ( $action !== 'D' ) { |
| 292 | + if ( $action === 'd' ) { |
| 293 | + if ( $rev > 1 ) { |
| 294 | + $link = $this->skin->makeExternalLink( // last rev |
| 295 | + "{$viewvc}{$safePath}?view=markup&pathrev=".($rev-1), |
| 296 | + $path . $from ); |
| 297 | + } else { |
| 298 | + $link = $safePath; // imported to SVN or something |
| 299 | + } |
| 300 | + } else { |
293 | 301 | $link = $this->skin->makeExternalLink( |
294 | | - "$viewvc$safePath?view=markup&pathrev=$rev", |
| 302 | + "{$viewvc}{$safePath}?view=markup&pathrev=$rev", |
295 | 303 | $path . $from ); |
296 | | - } else { |
297 | | - $link = $safePath; |
298 | 304 | } |
299 | | - if ( $action !== 'A' && $action !== 'D' ) { |
| 305 | + if ( $action !== 'a' && $action !== 'd' ) { |
300 | 306 | $diff = ' (' . |
301 | 307 | $this->skin->makeExternalLink( |
302 | 308 | "$viewvc$safePath?&pathrev=$rev&r1=$prev&r2=$rev", |