diff --git a/job.go b/job.go index 6074886..7086193 100644 --- a/job.go +++ b/job.go @@ -1302,19 +1302,25 @@ func jobGWithdraw(j Job) { b, _ := json.Marshal(p) log.Printf("jobGWithdraw : %s\n", string(b)) - if p.Status < 64 { + if (p.Status & 63) > 0 { if (p.Status & 1) == 1 { log.Printf("jobGWithdraw : Requesting res.\n") + p.Status = p.Status &^ 1 } else if (p.Status & 2) == 2 { log.Printf("jobGWithdraw : Requesting alch.\n") + p.Status = p.Status &^ 2 } else if (p.Status & 4) == 4 { log.Printf("jobGWithdraw : Requesting misc.\n") + p.Status = p.Status &^ 4 } else if (p.Status & 8) == 8 { log.Printf("jobGWithdraw : Requesting recipe.\n") + p.Status = p.Status &^ 8 } else if (p.Status & 16) == 16 { log.Printf("jobGWithdraw : Requesting part.\n") + p.Status = p.Status &^ 16 } else if (p.Status & 32) == 32 { log.Printf("jobGWithdraw : Requesting other.\n") + p.Status = p.Status &^ 32 } }