2a1b2c58c1fbc54cb24b1476670557fdfdfef187
braney
  Tue Aug 16 19:20:29 2011 -0700
cleaning up the library to remove a dependency on the cart that used to be necessary when private hubs were saved in the trash, rather than the hubStatus table.  This fixes up an ifdef that Tim did to fix some bug with right-click in v255
diff --git src/hg/lib/hdb.c src/hg/lib/hdb.c
index a33006a..e449473 100644
--- src/hg/lib/hdb.c
+++ src/hg/lib/hdb.c
@@ -3756,43 +3756,39 @@
 return trackTdb;
 }
 
 struct trackDb *tdbForTrack(char *db, char *track,struct trackDb **tdbList)
 /* Load trackDb object for a track. If track is composite, its subtracks
  * will also be loaded and inheritance will be handled; if track is a
  * subtrack then inheritance will be handled.  (Unless a subtrack has
  * "noInherit on"...) This will die if the current database does not have
  * a trackDb, but will return NULL if track is not found.
  * MAY pass in prepopulated trackDb list, or may receive the trackDb list as an inout. */
 {
 /* Get track list .*/
 struct trackDb *theTdbs = NULL;
 if (tdbList == NULL || *tdbList == NULL)
     {
-#define HGAPI_NEEDS_THIS
-#ifdef HGAPI_NEEDS_THIS
-    // This was removed becuase of missing cart. BUT CART ISN"T USED DOWN BLELOW
     // NOTE: Currently any call to this (hub or not), makes a tdbList and leaks it!
     if (isHubTrack(track))
         {
 	struct hash *hash = hashNew(0);
         // NOTE: cart is not even used!
-	theTdbs = hubConnectAddHubForTrackAndFindTdb((struct cart *)NULL,db, track, tdbList, hash);
+	theTdbs = hubConnectAddHubForTrackAndFindTdb(db, track, tdbList, hash);
         return hashFindVal(hash, track); // leaks tdbList and hash
 	}
     else
-#endif///def HGAPI_NEEDS_THIS
 	{
 	theTdbs = hTrackDb(db);
 	if (tdbList != NULL)
 	    *tdbList = theTdbs;
 	}
     }
 else
     theTdbs = *tdbList;
 return rFindTrack(0, theTdbs, track);
 }
 
 struct trackDb *hTrackDbForTrackAndAncestors(char *db, char *track)
 /* Load trackDb object for a track. If need be grab its ancestors too.
  * This does not load children. hTrackDbForTrack will handle children, and
  * is actually faster if being called on lots of tracks.  This function