[LON-CAPA-cvs] cvs: loncom /interface portfolio.pm

albertel lon-capa-cvs@mail.lon-capa.org
Tue, 24 Aug 2004 21:30:01 -0000


albertel		Tue Aug 24 17:30:01 2004 EDT

  Modified files:              
    /loncom/interface	portfolio.pm 
  Log:
  - style police
  
  
Index: loncom/interface/portfolio.pm
diff -u loncom/interface/portfolio.pm:1.30 loncom/interface/portfolio.pm:1.31
--- loncom/interface/portfolio.pm:1.30	Tue Aug 24 16:57:12 2004
+++ loncom/interface/portfolio.pm	Tue Aug 24 17:30:00 2004
@@ -194,7 +194,7 @@
 	      &Apache::lonhtmlcommon::select_recent('portfolio','currentpath',
 						    'this.form.submit();'));
     $r->print("</form>");
-    if ($is_empty){
+    if ($is_empty) {
         $displayOut = '<form method="post" action="/adm/portfolio">'.
         '<input type="hidden" name="action" value="deletedir" />'.
         '<input type="submit" name="deletedir" value="'.&mt("Delete Directory").'" />'.
@@ -203,7 +203,8 @@
         '</form>';
         
         $r->print($displayOut);
-    }else{
+	return;
+    }
     $r->print('<table border="0" cellspacing="2" cellpadding="2">'.
             '<tr><th>Actions</th><th>&nbsp;</th><th>Name</th><th>Size</th><th>Last Modified</th></tr>');
     my $href_location="/uploaded/$ENV{'user.domain'}/$ENV{'user.name'}/portfolio/$current_path/";
@@ -251,7 +252,6 @@
 #    $r->print('</td>><td>');
 #   $r->print(&display_actions($current_path, $currentFile, $isEmpty));
     $r->print('</table></form>');
-    }
 }
 
 sub open_form {
@@ -421,9 +421,9 @@
     } elsif ($ENV{'form.action'} eq 'delete') {
 	&delete($r);
     } elsif ($ENV{'form.action'} eq 'deletedir' && $ENV{'form.confirmed'}) {
-    &delete_dir_confirmed($r);
+	&delete_dir_confirmed($r);
     } elsif ($ENV{'form.action'} eq 'deletedir'){
-    &delete_dir($r);
+	&delete_dir($r);
     } elsif ($ENV{'form.action'} eq 'rename' && $ENV{'form.confirmed'}) {
 	&rename_confirmed($r);
     } elsif ($ENV{'form.action'} eq 'rename') {
@@ -445,10 +445,9 @@
     
 	# need to know if directory is empty so it can be removed if desired
 	my $is_empty=(@dir_list == 2);
-    &display_directory($r,$current_path,$is_empty,\@dir_list);
-    $r->print("</body>\n</html>\n");
-    $r->rflush();
-    return OK;
+	&display_directory($r,$current_path,$is_empty,\@dir_list);
+	$r->print("</body>\n</html>\n");
+	return OK;
     }
 }
 1;