Skip to content

Commit 082eb6e

Browse files
committed
fsrepo: simplify return logic
License: MIT Signed-off-by: Jakub Sztandera <[email protected]>
1 parent 6267f3e commit 082eb6e

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

repo/fsrepo/fsrepo.go

+1-5
Original file line numberDiff line numberDiff line change
@@ -300,11 +300,7 @@ func APIAddr(repoPath string) (ma.Multiaddr, error) {
300300

301301
s := string(buf[:n])
302302
s = strings.TrimSpace(s)
303-
m, err := ma.NewMultiaddr(s)
304-
if err != nil {
305-
return nil, err
306-
}
307-
return m, nil
303+
return ma.NewMultiaddr(s)
308304
}
309305

310306
// SetAPIAddr writes the API Addr to the /api file.

0 commit comments

Comments
 (0)