Skip to content

Commit

Permalink
fix: not join dir
Browse files Browse the repository at this point in the history
Signed-off-by: knqyf263 <[email protected]>
  • Loading branch information
knqyf263 committed Jun 19, 2024
1 parent 87fd73b commit 23ce7e6
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions pkg/fanal/analyzer/language/java/sbt/lockfile.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,12 @@ const version = 1
type sbtDependencyLockAnalyzer struct{}

func (a sbtDependencyLockAnalyzer) Analyze(_ context.Context, input analyzer.AnalysisInput) (*analyzer.AnalysisResult, error) {
filePath := filepath.Join(input.Dir, input.FilePath)
parser := lockfile.NewParser()

res, err := language.Analyze(types.Sbt, filePath, input.Content, parser)
res, err := language.Analyze(types.Sbt, input.FilePath, input.Content, parser)

if err != nil {
return nil, xerrors.Errorf("%s parse error: %w", filePath, err)
return nil, xerrors.Errorf("%s parse error: %w", input.FilePath, err)
}

return res, nil
Expand Down

0 comments on commit 23ce7e6

Please sign in to comment.