Skip to content

Commit 608df9f

Browse files
committed
Removed useless parameters in loadBoards (and back up in the call chain)
1 parent adf9f60 commit 608df9f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Diff for: hardware_loader.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ func loadPackage(targetPackage *types.Package, folder string) error {
143143
}
144144

145145
platform := getOrCreatePlatform(platforms, platformId)
146-
err = loadPlatform(platform, targetPackage.PackageId, subfolderPath)
146+
err = loadPlatform(platform, subfolderPath)
147147
if err != nil {
148148
return i18n.WrapError(err)
149149
}
@@ -167,7 +167,7 @@ func getOrCreatePlatform(platforms map[string]*types.Platform, platformId string
167167
return &targetPlatform
168168
}
169169

170-
func loadPlatform(targetPlatform *types.Platform, packageId string, folder string) error {
170+
func loadPlatform(targetPlatform *types.Platform, folder string) error {
171171
_, err := os.Stat(filepath.Join(folder, constants.FILE_BOARDS_TXT))
172172
if err != nil && !os.IsNotExist(err) {
173173
return i18n.WrapError(err)
@@ -179,7 +179,7 @@ func loadPlatform(targetPlatform *types.Platform, packageId string, folder strin
179179

180180
targetPlatform.Folder = folder
181181

182-
err = loadBoards(targetPlatform.Boards, packageId, targetPlatform.PlatformId, folder)
182+
err = loadBoards(targetPlatform.Boards, folder)
183183
if err != nil {
184184
return i18n.WrapError(err)
185185
}
@@ -207,7 +207,7 @@ func loadPlatform(targetPlatform *types.Platform, packageId string, folder strin
207207
return nil
208208
}
209209

210-
func loadBoards(boards map[string]*types.Board, packageId string, platformId string, folder string) error {
210+
func loadBoards(boards map[string]*types.Board, folder string) error {
211211
boardsProperties, err := properties.Load(filepath.Join(folder, constants.FILE_BOARDS_TXT))
212212
if err != nil {
213213
return i18n.WrapError(err)

0 commit comments

Comments
 (0)