Add TODOs on pkg/server/share.go

Change-Id: Ibc01fc6f9c266669bd556348075fdfae66cfc408
This commit is contained in:
Brad Fitzpatrick 2013-09-19 10:28:12 +01:00
parent 5c7653b9b0
commit 5dad68ae49
1 changed files with 4 additions and 0 deletions

View File

@ -75,6 +75,8 @@ func newShareFromConfig(ld blobserver.Loader, conf jsonconfig.Obj) (h http.Handl
}
// Unauthenticated user. Be paranoid.
//
// TODO: check IsTransitive on the share blob? http://camlistore.org/issue/226
func handleGetViaSharing(conn http.ResponseWriter, req *http.Request,
blobRef blob.Ref, fetcher blob.StreamingFetcher) {
if !httputil.IsGet(req) {
@ -176,12 +178,14 @@ func handleGetViaSharing(conn http.ResponseWriter, req *http.Request,
viaPathOkay = true
if assemble, _ := strconv.ParseBool(req.FormValue("assemble")); assemble {
// TODO: check IsTransitive on the share blob? http://camlistore.org/issue/226
dh := &DownloadHandler{
Fetcher: fetcher,
// TODO(aa): It would be nice to specify a local cache here, as the UI handler does.
}
dh.ServeHTTP(conn, req, blobRef)
} else {
// TODO: check IsTransitive on the share blob? http://camlistore.org/issue/226
gethandler.ServeBlobRef(conn, req, blobRef, fetcher)
}
}