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

www www@source.lon-capa.org
Thu, 23 Sep 2010 21:50:37 -0000


www		Thu Sep 23 21:50:37 2010 EDT

  Modified files:              
    /loncom/interface	lonpickcourse.pm 
  Log:
  Give a different warning if the intended course owner was not specified yet.
  
  
Index: loncom/interface/lonpickcourse.pm
diff -u loncom/interface/lonpickcourse.pm:1.99 loncom/interface/lonpickcourse.pm:1.100
--- loncom/interface/lonpickcourse.pm:1.99	Thu Jul  8 23:19:19 2010
+++ loncom/interface/lonpickcourse.pm	Thu Sep 23 21:50:37 2010
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Pick a course
 #
-# $Id: lonpickcourse.pm,v 1.99 2010/07/08 23:19:19 raeburn Exp $
+# $Id: lonpickcourse.pm,v 1.100 2010/09/23 21:50:37 www Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -830,7 +830,11 @@
 
 sub get_coordinator_cloneable {
     my ($cloneruname,$clonerudom,$type) = @_;
-    if (&Apache::lonnet::homeserver($cloneruname,$clonerudom) eq 'no_host') {
+    if (($cloneruname!~/\w/) || ($clonerudom!~/\w/)) {
+        my $warning = '<div class="LC_warning">'.&mt('Intended course owner not specified').
+                   '</div>';
+        return ('',$warning);
+    } elsif (&Apache::lonnet::homeserver($cloneruname,$clonerudom) eq 'no_host') {
         my $warning = '<div class="LC_error">'.&mt('Intended course owner does not exist').
                    '</div>';
         return ('',$warning);