Skip to content

Commit 0690060

Browse files
committed
fix unreachable guard for getWriteReportFamily
1 parent 577eba4 commit 0690060

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

core/capabilities/remote/executable/hasher.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ var (
155155

156156
func getWriteReportFamily(msg *types.MessageBody) (writeReportFamily, error) {
157157
ss := strings.Split(msg.CapabilityId, ":")
158-
if len(ss) < 1 {
158+
if len(ss) < 1 || ss[0] == "" {
159159
return "", errors.New("failed to parse family from capability id")
160160
}
161161
family := ss[0]

0 commit comments

Comments
 (0)