Re: bugzilla validation

On Sat, 2004-01-03 at 23:09, Joe Shaw wrote: 
> On Sat, 2004-01-03 at 18:34, David Stahl wrote:
> > This is my first patch so feel free to criticize style or approach :)
> Being a style nazi, the patch should conform to the existing coding
> style.  That is, spaces after just about everything:

Thanks for the comments. It looks like Andrew made some of the style
changes before applying the patch, and this patch to current CVS fixes
the function declaration and function calls. If you haven't gotten the
latest CVS you'll need to apply my other patch first.

Index: backends/backend-bugzilla.cs
RCS file: /cvs/gnome/dashboard/backends/backend-bugzilla.cs,v
retrieving revision 1.15
diff -u -r1.15 backend-bugzilla.cs
--- backends/backend-bugzilla.cs	4 Jan 2004 03:19:07 -0000	1.15
+++ backends/backend-bugzilla.cs	4 Jan 2004 04:28:58 -0000
@@ -106,7 +106,7 @@
 			// see if the bug was even found. If there wasn't a bug, there will be
 			// an error attribute on the /bug element that says NotFound if one didn't exist.
-			if (! IsValidBug(xml))
+			if (!IsValidBug (xml))
 				return null;
 			try { 
@@ -170,18 +170,18 @@
 		// Determines if the bug is valid or if we searched on some number
 		// that we thought might have been a bugzilla number.
 		// Rather than return all '???' let's just ignore them
-		private bool IsValidBug(XmlDocument xml)
+		private bool IsValidBug (XmlDocument xml)
 			try {			
 				XmlNode node;
-				node = xml.SelectSingleNode("/bugzilla/bug");
+				node = xml.SelectSingleNode ("/bugzilla/bug");
 				// if we can't find the "bug" element, then it's not valid
 				if (node == null)
 					return false;				
 				XmlNode attrib;
-				attrib = node.Attributes.GetNamedItem("error");
+				attrib = node.Attributes.GetNamedItem ("error");
 				// if there's no error attribute, it's legit
 				// Note: I don't know what possible values for "error" are.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]