aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2023-05-11 16:16:27 +0200
committerChocobozzz <me@florianbigard.com>2023-05-11 16:16:27 +0200
commit85c20aaeb90ef0e0f44c377e62c323fde275cdde (patch)
tree79d09e1b6f1746398c2ea4f0279ac54fa2be96dd /server/controllers/api
parent823c34c07fc0df81110098ee1032e9d3ed70b662 (diff)
downloadPeerTube-85c20aaeb90ef0e0f44c377e62c323fde275cdde.tar.gz
PeerTube-85c20aaeb90ef0e0f44c377e62c323fde275cdde.tar.zst
PeerTube-85c20aaeb90ef0e0f44c377e62c323fde275cdde.zip
Set actor preferred name case insensitive
Diffstat (limited to 'server/controllers/api')
-rw-r--r--server/controllers/api/users/my-subscriptions.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/server/controllers/api/users/my-subscriptions.ts b/server/controllers/api/users/my-subscriptions.ts
index 6ba8ba597..6e2aa3711 100644
--- a/server/controllers/api/users/my-subscriptions.ts
+++ b/server/controllers/api/users/my-subscriptions.ts
@@ -99,7 +99,7 @@ async function areSubscriptionsExist (req: express.Request, res: express.Respons
99 const obj = results.find(r => { 99 const obj = results.find(r => {
100 const server = r.ActorFollowing.Server 100 const server = r.ActorFollowing.Server
101 101
102 return r.ActorFollowing.preferredUsername === sanitizedHandle.name && 102 return r.ActorFollowing.preferredUsername.toLowerCase() === sanitizedHandle.name.toLowerCase() &&
103 ( 103 (
104 (!server && !sanitizedHandle.host) || 104 (!server && !sanitizedHandle.host) ||
105 (server.host === sanitizedHandle.host) 105 (server.host === sanitizedHandle.host)