From 4adbf9a93412d01c29ae686866c338359eaf0e82 Mon Sep 17 00:00:00 2001 From: Emil Date: Mon, 4 Feb 2019 22:31:52 +0300 Subject: [PATCH] checkers: simplify flagName (#799) --- checkers/flagName_checker.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/checkers/flagName_checker.go b/checkers/flagName_checker.go index e40efb524..1d43ba521 100644 --- a/checkers/flagName_checker.go +++ b/checkers/flagName_checker.go @@ -38,7 +38,7 @@ func (c *flagNameChecker) VisitExpr(expr ast.Expr) { } sym := calledExpr.Sel pkg := obj.Imported() - if !isStdlibPkg(pkg) || obj.Name() != "flag" { + if pkg.Path() != "flag" { return }