Don't need type declarations on toplevel vars.
Fix nil panic when reading an error.