Function
cloneTaskOwner
(owner *taskpkg.Ownership)
Source from the content-addressed store, hash-verified
| 6080 | } |
| 6081 | |
| 6082 | func cloneTaskOwner(owner *taskpkg.Ownership) *taskpkg.Ownership { |
| 6083 | if owner == nil { |
| 6084 | return nil |
| 6085 | } |
| 6086 | cloned := *owner |
| 6087 | cloned.Kind = taskpkg.OwnerKind(strings.TrimSpace(string(cloned.Kind))) |
| 6088 | cloned.Ref = strings.TrimSpace(cloned.Ref) |
| 6089 | return &cloned |
| 6090 | } |
| 6091 | |
| 6092 | func cloneJSON(raw json.RawMessage) json.RawMessage { |
| 6093 | if len(raw) == 0 { |
Tested by
no test coverage detected