From 95d5b0cfc18460bd76e6f7f8795c331d5b359963 Mon Sep 17 00:00:00 2001 From: shoopea Date: Sun, 5 Jan 2020 18:00:54 +0800 Subject: [PATCH] test --- job.go | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) 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 } }