Skip to content

Commit

Permalink
fix: composite literal uses unkeyed fields
Browse files Browse the repository at this point in the history
  • Loading branch information
xhofe committed Jun 11, 2022
1 parent 77b0c69 commit 3135775
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions internal/operations/driver.go
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
package operations

import (
"reflect"
"strings"

"github.com/alist-org/alist/v3/internal/driver"
"github.com/pkg/errors"
log "github.com/sirupsen/logrus"
"reflect"
"strings"
)

type New func() driver.Driver
Expand All @@ -31,7 +32,10 @@ func registerDriverItems(config driver.Config, addition driver.Additional) {
tAddition := reflect.TypeOf(addition)
mainItems := getMainItems(config)
additionalItems := getAdditionalItems(tAddition)
driverItemsMap[config.Name] = driver.Items{mainItems, additionalItems}
driverItemsMap[config.Name] = driver.Items{
Main: mainItems,
Additional: additionalItems,
}
}

func getMainItems(config driver.Config) []driver.Item {
Expand Down

0 comments on commit 3135775

Please sign in to comment.