batazor/go-auth

View on GitHub

Showing 99 of 99 total issues

exported function HashPassword should have comment or be unexported
Open

func HashPassword(password string) (string, error) {
Severity: Minor
Found in utils/crypto/crypto.go by golint

exported type StructuredLogger should have comment or be unexported
Open

type StructuredLogger struct {
Severity: Minor
Found in utils/types.go by golint

exported function GetLogEntry should have comment or be unexported
Open

func GetLogEntry(r *http.Request) logrus.FieldLogger {
Severity: Minor
Found in utils/logger.go by golint

exported var GrpcClient should have comment or be unexported
Open

    GrpcClient *grpc.ClientConn
Severity: Minor
Found in grpc/server/server.go by golint

Unordered list style
Open

* Go
Severity: Info
Found in README.md by markdownlint

MD004 - Unordered list style

Tags: bullet, ul

Aliases: ul-style

Parameters: style ("consistent", "asterisk", "plus", "dash"; default "consistent")

This rule is triggered when the symbols used in the document for unordered list items do not match the configured unordered list style:

* Item 1
+ Item 2
- Item 3

To fix this issue, use the configured style for list items throughout the document:

* Item 1
* Item 2
* Item 3

Note: the configured list style can be a specific symbol to use (asterisk, plus, dash), or simply require that the usage be consistent within the document.

exported function GetConnClient should have comment or be unexported
Open

func GetConnClient() *grpc.ClientConn {
Severity: Minor
Found in grpc/server/server.go by golint

don't use underscores in Go names; var is_err should be isErr
Open

    is_err := CheckUniqueUser(w, user)
Severity: Minor
Found in handlers/user/user.go by golint

Multiple consecutive blank lines
Open


Severity: Info
Found in README.md by markdownlint

MD012 - Multiple consecutive blank lines

Tags: whitespace, blank_lines

Aliases: no-multiple-blanks

This rule is triggered when there are multiple consecutive blank lines in the document:

Some text here


Some more text here

To fix this, delete the offending lines:

Some text here

Some more text here

Note: this rule will not be triggered if there are multiple consecutive blank lines inside code blocks.

exported function Delete should have comment or be unexported
Open

func Delete(w http.ResponseWriter, r *http.Request) {
Severity: Minor
Found in handlers/user/user.go by golint

var userId should be userID
Open

    userId := user.Id.Hex()
Severity: Minor
Found in handlers/user/user_test.go by golint

exported function Delete should have comment or be unexported
Open

func Delete(token string) error {
Severity: Minor
Found in models/session/session.go by golint

exported function Getenv should have comment or be unexported
Open

func Getenv(key, fallback string) string {
Severity: Minor
Found in utils/env.go by golint

Trailing spaces
Open

    
Severity: Info
Found in README.md by markdownlint

MD009 - Trailing spaces

Tags: whitespace

Aliases: no-trailing-spaces

Parameters: br_spaces (number; default: 0)

This rule is triggered on any lines that end with whitespace. To fix this, find the line that is triggered and remove any trailing spaces from the end.

The brspaces parameter allows an exception to this rule for a specific amount of trailing spaces used to insert an explicit line break/br element. For example, set brspaces to 2 to allow exactly 2 spaces at the end of a line.

Note: you have to set brspaces to 2 or higher for this exception to take effect - you can't insert a br element with just a single trailing space, so if you set brspaces to 1, the exception will be disabled, just as if it was set to the default of 0.

Multiple consecutive blank lines
Open


Severity: Info
Found in README.md by markdownlint

MD012 - Multiple consecutive blank lines

Tags: whitespace, blank_lines

Aliases: no-multiple-blanks

This rule is triggered when there are multiple consecutive blank lines in the document:

Some text here


Some more text here

To fix this, delete the offending lines:

Some text here

Some more text here

Note: this rule will not be triggered if there are multiple consecutive blank lines inside code blocks.

Line length
Open

[![](https://images.microbadger.com/badges/image/batazor/go-auth.svg)](https://microbadger.com/images/batazor/go-auth "Get your own image badge on microbadger.com")
Severity: Info
Found in README.md by markdownlint

MD013 - Line length

Tags: line_length

Aliases: line-length Parameters: linelength, codeblocks, tables (number; default 80, boolean; default true)

This rule is triggered when there are lines that are longer than the configured line length (default: 80 characters). To fix this, split the line up into multiple lines.

This rule has an exception where there is no whitespace beyond the configured line length. This allows you to still include items such as long URLs without being forced to break them in the middle.

You also have the option to exclude this rule for code blocks and tables. To do this, set the code_blocks and/or tables parameters to false.

Code blocks are included in this rule by default since it is often a requirement for document readability, and tentatively compatible with code rules. Still, some languages do not lend themselves to short lines.

struct field Id should be ID
Open

    Id            string `json:"id"`
Severity: Minor
Found in handlers/oauth/types.go by golint

exported function Debug should have comment or be unexported
Open

func Debug(w http.ResponseWriter, r *http.Request) {
Severity: Minor
Found in handlers/session/session.go by golint

exported function Find should have comment or be unexported
Open

func Find(user User) (*[]User, error) {
Severity: Minor
Found in models/user/user.go by golint

error should be the last type when returning multiple items
Open

func Add(user User) (error, User) {
Severity: Minor
Found in models/user/user.go by golint

Your code does not pass gofmt in 1 place. Go fmt your code!
Open

// Code generated by protoc-gen-go. DO NOT EDIT.
Severity: Minor
Found in grpc/mail/mail.pb.go by gofmt
Severity
Category
Status
Source
Language