refactor: add StorageProtocol to S5ProtocolResult
This commit is contained in:
parent
6f3f6015fe
commit
b52383b123
|
@ -51,10 +51,11 @@ type S5ProtocolParams struct {
|
||||||
|
|
||||||
type S5ProtocolResult struct {
|
type S5ProtocolResult struct {
|
||||||
fx.Out
|
fx.Out
|
||||||
Protocol registry.Protocol `group:"protocol"`
|
Protocol registry.Protocol `group:"protocol"`
|
||||||
S5Protocol *S5Protocol
|
S5Protocol *S5Protocol
|
||||||
S5NodeConfig *s5config.NodeConfig
|
S5NodeConfig *s5config.NodeConfig
|
||||||
Db *bolt.DB
|
Db *bolt.DB
|
||||||
|
StorageProtocol storage.StorageProtocol
|
||||||
}
|
}
|
||||||
|
|
||||||
type S5ProviderStoreParams struct {
|
type S5ProviderStoreParams struct {
|
||||||
|
@ -92,10 +93,11 @@ func NewS5Protocol(
|
||||||
}
|
}
|
||||||
|
|
||||||
return S5ProtocolResult{
|
return S5ProtocolResult{
|
||||||
Protocol: proto,
|
Protocol: proto,
|
||||||
S5Protocol: proto,
|
S5Protocol: proto,
|
||||||
S5NodeConfig: cfg,
|
S5NodeConfig: cfg,
|
||||||
Db: cfg.DB,
|
Db: cfg.DB,
|
||||||
|
StorageProtocol: GetStorageProtocol(proto),
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue