Skip to content

Commit

Permalink
refactor: rearrange code branches
Browse files Browse the repository at this point in the history
  • Loading branch information
gabotechs committed Dec 25, 2023
1 parent 4dcb843 commit 29e8553
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions internal/python/exports.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,21 +83,13 @@ func (l *Language) ParseExports(file *python_grammar.File) (*language.ExportsEnt
})
case stmt.Function != nil:
exports = append(exports, language.ExportEntry{
Names: []language.ExportName{
{
Original: stmt.Function.Name,
},
},
Path: file.Path,
Names: []language.ExportName{{Original: stmt.Function.Name}},
Path: file.Path,
})
case stmt.Class != nil:
exports = append(exports, language.ExportEntry{
Names: []language.ExportName{
{
Original: stmt.Class.Name,
},
},
Path: file.Path,
Names: []language.ExportName{{Original: stmt.Class.Name}},
Path: file.Path,
})
}
}
Expand Down

0 comments on commit 29e8553

Please sign in to comment.