mirror of
https://github.com/octoleo/syncthing.git
synced 2024-11-18 11:05:14 +00:00
all: Fix unused method receiver (further) (#8466)
Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com>
This commit is contained in:
parent
79f8bd0f33
commit
81d8fa1cb5
@ -214,7 +214,7 @@ func (t *quicListener) NATType() string {
|
||||
|
||||
type quicListenerFactory struct{}
|
||||
|
||||
func (f *quicListenerFactory) Valid(config.Configuration) error {
|
||||
func (*quicListenerFactory) Valid(config.Configuration) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -172,7 +172,7 @@ func (t *relayListener) String() string {
|
||||
return t.uri.String()
|
||||
}
|
||||
|
||||
func (t *relayListener) NATType() string {
|
||||
func (*relayListener) NATType() string {
|
||||
return "unknown"
|
||||
}
|
||||
|
||||
|
@ -83,15 +83,15 @@ func (f *fakeDiscovery) Lookup(_ context.Context, _ protocol.DeviceID) (addresse
|
||||
return f.addresses, nil
|
||||
}
|
||||
|
||||
func (f *fakeDiscovery) Error() error {
|
||||
func (*fakeDiscovery) Error() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (f *fakeDiscovery) String() string {
|
||||
func (*fakeDiscovery) String() string {
|
||||
return "fake"
|
||||
}
|
||||
|
||||
func (f *fakeDiscovery) Cache() map[protocol.DeviceID]CacheEntry {
|
||||
func (*fakeDiscovery) Cache() map[protocol.DeviceID]CacheEntry {
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -133,14 +133,14 @@ func (f *slowDiscovery) Lookup(_ context.Context, _ protocol.DeviceID) (addresse
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
func (f *slowDiscovery) Error() error {
|
||||
func (*slowDiscovery) Error() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (f *slowDiscovery) String() string {
|
||||
func (*slowDiscovery) String() string {
|
||||
return "fake"
|
||||
}
|
||||
|
||||
func (f *slowDiscovery) Cache() map[protocol.DeviceID]CacheEntry {
|
||||
func (*slowDiscovery) Cache() map[protocol.DeviceID]CacheEntry {
|
||||
return nil
|
||||
}
|
||||
|
@ -617,7 +617,7 @@ func (*fakeFS) Unhide(_ string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (fs *fakeFS) Glob(_ string) ([]string, error) {
|
||||
func (*fakeFS) Glob(_ string) ([]string, error) {
|
||||
// gnnh we don't seem to actually require this in practice
|
||||
return nil, errors.New("not implemented")
|
||||
}
|
||||
|
@ -175,7 +175,7 @@ func (*fakeModel) IndexUpdate(_ DeviceID, _ string, _ []FileInfo) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *fakeModel) Request(_ DeviceID, _, _ string, _, size int32, offset int64, _ []byte, _ uint32, _ bool) (RequestResponse, error) {
|
||||
func (*fakeModel) Request(_ DeviceID, _, _ string, _, size int32, offset int64, _ []byte, _ uint32, _ bool) (RequestResponse, error) {
|
||||
// We write the offset to the end of the buffer, so the receiver
|
||||
// can verify that it did in fact get some data back over the
|
||||
// connection.
|
||||
|
@ -113,14 +113,14 @@ func (v external) Archive(filePath string) error {
|
||||
return errors.New("file was not removed by external script")
|
||||
}
|
||||
|
||||
func (v external) GetVersions() (map[string][]FileVersion, error) {
|
||||
func (external) GetVersions() (map[string][]FileVersion, error) {
|
||||
return nil, ErrRestorationNotSupported
|
||||
}
|
||||
|
||||
func (v external) Restore(_ string, _ time.Time) error {
|
||||
func (external) Restore(_ string, _ time.Time) error {
|
||||
return ErrRestorationNotSupported
|
||||
}
|
||||
|
||||
func (v external) Clean(_ context.Context) error {
|
||||
func (external) Clean(_ context.Context) error {
|
||||
return nil
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user