Lease.Lease.take.go: def of bend-kube-runtime@0.2.0.0 Import: import bend-kube-runtime@0.2.0.0/src/lease.bend as Lease Lines 83-89 of bend-kube-runtime@0.2.0.0/src/lease.bend: https://jend.leeeet.dev/read.txt?path=bend-kube-runtime@0.2.0.0/src/lease.bend&start_line=83&end_line=89 import Base import bend-kube-runtime@0.2.0.0/src/json.bend as J def Lease.take.go(+l: J.Json, me: String, +dur: U32, +now: String, ours: Bool) -> J.Json: match ours: case True{}: J.Json.set(l, "spec", Lease.new_spec(me, dur, J.Json.str_or(Lease.spec(l, "acquireTime"), now), now, Lease.transitions(l))) case False{}: J.Json.set(l, "spec", Lease.new_spec(me, dur, now, now, (Lease.transitions(l) + 1 : U32))) Uses (10): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.add https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/json.bend&name=Json https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/json.bend&name=Json.set https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/json.bend&name=Json.str_or https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/lease.bend&name=Lease.new_spec https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/lease.bend&name=Lease.spec https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/lease.bend&name=Lease.transitions