diff --git a/server/services/rTorrent/constants/methodCallConfigs/torrentPeer.ts b/server/services/rTorrent/constants/methodCallConfigs/torrentPeer.ts index 3addee1b..da8bfb40 100644 --- a/server/services/rTorrent/constants/methodCallConfigs/torrentPeer.ts +++ b/server/services/rTorrent/constants/methodCallConfigs/torrentPeer.ts @@ -3,7 +3,10 @@ import {stringTransformer, booleanTransformer, numberTransformer} from '../../ut const torrentPeerMethodCallConfigs = { address: { methodCall: 'p.address=', - transformValue: stringTransformer, + transformValue: (value: unknown) => { + const address = value as string; + return address.startsWith('[') ? address.slice(1, -1) : address; + }, }, clientVersion: { methodCall: 'p.client_version=',