Pass error to function caller instead of calling log.Fatal
Remove unused import