public static boolean deleteDirectory(File directoryToBeDeleted) {
    File[] allContents = directoryToBeDeleted.listFiles();
    if (allContents != null) {
      for (File file : allContents) {
        deleteDirectory(file);
      }
    }
    return directoryToBeDeleted.delete();
  }
Fetch media path string.

@param media the media
@param browserName the browser name
@return the string
KITE-Framework/src/main/java/org/webrtc/kite/Utils.java