markbates / markbates/goth

BeginAuthHandler prints error instead of returning the error

Open
#437 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
6.6k
Forks
631
PR merge metrics
No merged PRs in 30d

Description

https://github.com/markbates/goth/blob/9dc8905b41c845fa22b7ecd3fb8f079dac3e923e/gothic/gothic.go#L68

I was wondering why this line prints to the console, since the function could simply return the error so that the user of the library can handle the error. I'm still new to this library and Go in general, so maybe there's more to it, but I wanted to point it out regardless. Thanks!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading gothic/gothic.go around line 68 and the BeginAuthHandler entry point to understand the current error path. Done means the error is returned for the library user to handle instead of being printed, while preserving the affected authentication flow.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
authentication
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.