ziscky/mock-pesa

View on GitHub
c2b/api.go

Summary

Maintainability
A
35 mins
Test Coverage

Method C2B.parseRequest has 5 return statements (exceeds 4 allowed).
Open

func (c2b *C2B) parseRequest(r *http.Request) http.HandlerFunc {
    body, err := ioutil.ReadAll(r.Body)

    processCheckoutOp := &ProcessCheckoutRequest{}
    confirmTrxOp := &ConfirmTransactionRequest{}
Severity: Major
Found in c2b/api.go - About 35 mins to fix

    2: cannot find package "github.com/gorilla/mux" in any of:
    Open

        "github.com/gorilla/mux"
    Severity: Minor
    Found in c2b/api.go by govet

    Your code does not pass gofmt in 13 places. Go fmt your code!
    Open

    /*
    Severity: Minor
    Found in c2b/api.go by gofmt

    exported method C2B.Clear should have comment or be unexported
    Open

    func (c2b *C2B) Clear() {
    Severity: Minor
    Found in c2b/api.go by golint

    package comment should be of the form "Package c2b ..."
    Open

    /*
    Severity: Minor
    Found in c2b/api.go by golint

    There are no issues that match your filters.

    Category
    Status