This change is mostly defensive; when checking for the returned error, it's easy to make a mistake, and check for a "local" error, not the actual returned error. This patch changes the function to use a named return variable, which is checked in the defer. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
3.7 KiB
3.7 KiB