From 2a2a4396ec935a057bcffe03006e8a38aaca6880 Mon Sep 17 00:00:00 2001 From: Anant Prakash Date: Thu, 7 Jun 2018 19:41:51 +0530 Subject: [PATCH] Use const AppServiceDeviceID --- src/github.com/matrix-org/dendrite/clientapi/auth/auth.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/github.com/matrix-org/dendrite/clientapi/auth/auth.go b/src/github.com/matrix-org/dendrite/clientapi/auth/auth.go index 4965dbf1..24c3386d 100644 --- a/src/github.com/matrix-org/dendrite/clientapi/auth/auth.go +++ b/src/github.com/matrix-org/dendrite/clientapi/auth/auth.go @@ -24,6 +24,7 @@ import ( "net/http" "strings" + "github.com/matrix-org/dendrite/appservice/types" "github.com/matrix-org/dendrite/clientapi/auth/authtypes" "github.com/matrix-org/dendrite/clientapi/httputil" "github.com/matrix-org/dendrite/clientapi/jsonerror" @@ -106,7 +107,7 @@ func VerifyUserFromRequest( // Create a dummy device for AS user dev := authtypes.Device{ // Use AS dummy device ID - ID: "AS_Device", + ID: types.AppServiceDeviceID, // User the AS is masquerading as. UserID: userID, // AS dummy device has AS's token.