979ae40501044410b8375bdb5840dcdfcb70c712
chmalee
  Wed Oct 2 12:26:27 2024 -0700
Working hub deletion

diff --git src/hg/inc/userdata.h src/hg/inc/userdata.h
index 8a2095a..7d7d8c9 100644
--- src/hg/inc/userdata.h
+++ src/hg/inc/userdata.h
@@ -45,30 +45,33 @@
 char *getDataDir(char *userName);
 /* Return the full path to the user specific data directory, can be configured via hg.conf
  * on hgwdev, this is /data/apache/userdata/userStore/hash/userName/
  * on the RR, this is /userdata/userStore/hash/userName/ */
 
 char *prefixUserFile(char *userName, char *fname);
 /* Allocate a new string that contains the full per-user path to fname, NULL otherwise */
 
 void addNewFileForUser(char *userName, char *fileName, long long fileSize, char *fileType,
         time_t lastModified, char *hubName, char *db, char *location);
 /* We created a file for a user, now add an entry to the hubSpace table for it */
 
 void removeFileForUser(char *fname, char *userName);
 /* Remove a file for this user if it exists */
 
+void removeHubForUser(char *path, char *userName);
+/* Remove a hub directory for this user (and all files in the directory), if it exists */
+
 struct userHubs *listHubsForUser(char *userName);
 /* Lists the directories for a particular user */
 
 struct userFiles *listFilesForUserHub(char *userName, char *hubName);
 /* Get all the files for a particular hub for a particular user */
 
 struct hubSpace *listFilesForUser(char *userName);
 /* Return the files the user has uploaded */
 
 long long getMaxUserQuota(char *userName);
 /* Return how much space is allocated for this user or the default */
 
 long long checkUserQuota(char *userName);
 /* Return the amount of space a user is currently using */