minor nit: the `else` is redundant since we return early from `if (err)`

(actually this is my fault, but might as well clean it up while we're here)