This commit is contained in:
Chris Lu
2013-02-10 09:44:44 -08:00
parent d4e5a22e53
commit 79d11ac951
8 changed files with 30 additions and 30 deletions

View File

@@ -32,11 +32,11 @@ var cmdUpload = &Command{
}
type AssignResult struct {
Fid string "fid"
Url string "url"
PublicUrl string "publicUrl"
Fid string `json:"fid"`
Url string `json:"url"`
PublicUrl string `json:"publicUrl"`
Count int
Error string "error"
Error string `json:"error"`
}
func assign(count int) (*AssignResult, error) {
@@ -74,9 +74,9 @@ func upload(filename string, server string, fid string) (int, error) {
}
type SubmitResult struct {
Fid string "fid"
Size int "size"
Error string "error"
Fid string `json:"fid"`
Size int `json:"size"`
Error string `json:"error"`
}
func submit(files []string) []SubmitResult {

View File

@@ -242,7 +242,7 @@ func DeleteHandler(w http.ResponseWriter, r *http.Request) {
n.Size = 0
ret, err := store.Delete(volumeId, n)
if err != nil {
log.Printf("delete error: %s\n", err)
log.Println("delete error:", err)
return
}