Showing 21 of 23 total issues
Function render
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const {to, from, result, status, err} = this.state;
const {path, duration, touched} = result || {};
let body = null;
Avoid deeply nested control flow statements. Open
Open
if linkPath.Len() < foundPath.Len() {
foundPath.Prev = linkPath.Prev
}
should not use dot imports Open
Open
. "github.com/wgoodall01/wikipath/wp"
- Exclude checks
exported type HttpError should have comment or be unexported Open
Open
type HttpError struct {
- Exclude checks
type HttpError should be HTTPError Open
Open
type HttpError struct {
- Exclude checks
exported function NewRandomHandler should have comment or be unexported Open
Open
func NewRandomHandler(ind *wp.Index) *RandomHandler {
- Exclude checks
don't use ALL_CAPS in Go names; use CamelCase Open
Open
const MAX_DEPTH int = 10 // Maximum query depth.
- Exclude checks
if block ends with a return statement, so drop this else and outdent its block Open
Open
} else {
- Exclude checks
exported type QueryHandler should have comment or be unexported Open
Open
type QueryHandler struct {
- Exclude checks
exported function NewQueryHandler should have comment or be unexported Open
Open
func NewQueryHandler(ind *wp.Index) *QueryHandler {
- Exclude checks
exported const MAX_DEPTH should have comment or be unexported Open
Open
const MAX_DEPTH int = 10 // Maximum query depth.
- Exclude checks
exported function NewHttpError should have comment or be unexported Open
Open
func NewHttpError(status int, message string) *HttpError {
- Exclude checks
exported type RandomHandler should have comment or be unexported Open
Open
type RandomHandler struct {
- Exclude checks
func NewHttpError should be NewHTTPError Open
Open
func NewHttpError(status int, message string) *HttpError {
- Exclude checks
exported method IndexPath.Len should have comment or be unexported Open
Open
func (path *IndexPath) Len() int {
- Exclude checks
exported type PathResponse should have comment or be unexported Open
Open
type PathResponse struct {
- Exclude checks
exported type RandomResponse should have comment or be unexported Open
Open
type RandomResponse struct {
- Exclude checks
2: cannot find package "github.com/urfave/cli" in any of: Open
Open
"github.com/urfave/cli"
- Exclude checks
should not use dot imports Open
Open
. "github.com/wgoodall01/wikipath/wp"
- Exclude checks
exported method HttpError.Send should have comment or be unexported Open
Open
func (he *HttpError) Send(w http.ResponseWriter) {
- Exclude checks