[MOBY-guts] biomoby commit

Mark Wilkinson mwilkinson at pub.open-bio.org
Wed Aug 18 23:40:03 UTC 2004


mwilkinson
Wed Aug 18 19:40:03 EDT 2004
Update of /home/repository/moby/moby-live/Perl/MOBY
In directory pub.open-bio.org:/tmp/cvs-serv29925/MOBY

Modified Files:
	Central.pm 
Log Message:
after noticing a service that had managed to become registered incorrectly, I think I have fixed an error that allowed registration of services that consumed collections of nothing.

moby-live/Perl/MOBY Central.pm,1.138,1.139
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/Central.pm,v
retrieving revision 1.138
retrieving revision 1.139
diff -u -r1.138 -r1.139
--- /home/repository/moby/moby-live/Perl/MOBY/Central.pm	2004/07/30 01:14:44	1.138
+++ /home/repository/moby/moby-live/Perl/MOBY/Central.pm	2004/08/18 23:40:03	1.139
@@ -1219,6 +1219,7 @@
         
 		my $Simples = $node->getElementsByTagName('Simple');
 		my $length = $Simples->getLength;
+        unless ($length > 0){return (-1, "Your collection must be a collection of one or more Simple types");}
 		for (my $x=0; $x<$length; ++$x){
 			my ($success, $message) = &_registerArticles($SVC, $inout, $Simples->item($x),$collection_id);
 			unless ($success == 1){return (-1, $message);}




More information about the MOBY-guts mailing list