vulnerabilities, vulnerabilities, vulnerabilities...
This commit is contained in:
parent
ab89f07493
commit
8dafeb06a9
4 changed files with 110 additions and 49 deletions
|
|
@ -66,7 +66,7 @@ public class Requests
|
|||
public static async Task<string> DmInvite(string id, string targetId)
|
||||
{
|
||||
bool isLocal = Account.Utils.IsUserLocal(targetId, out string domain);
|
||||
string tId = Account.Utils.GetIdFromUsernameWD(targetId);
|
||||
string tId = Account.Utils.GetValidIdOrZero(targetId);
|
||||
|
||||
string checkDmId = Account.Utils.GetDmId(id, DOMAIN, tId, domain);
|
||||
if (Fs.Exists($"{ROOMS_DIR}/dms/{DOMAIN}/{checkDmId}"))
|
||||
|
|
@ -116,7 +116,7 @@ public class Requests
|
|||
public static async Task<string> DmInviteRevoke(string id, string targetId)
|
||||
{
|
||||
bool isLocal = Account.Utils.IsUserLocal(targetId, out string domain);
|
||||
string tId = Account.Utils.GetIdFromUsernameWD(targetId);
|
||||
string tId = Account.Utils.GetValidIdOrZero(targetId);
|
||||
|
||||
if (!isLocal) //federation
|
||||
{
|
||||
|
|
@ -145,7 +145,7 @@ public class Requests
|
|||
public static async Task<string> DmInviteDecline(string id, string targetId)
|
||||
{
|
||||
bool isLocal = Account.Utils.IsUserLocal(targetId, out string domain);
|
||||
string tId = Account.Utils.GetIdFromUsernameWD(targetId);
|
||||
string tId = Account.Utils.GetValidIdOrZero(targetId);
|
||||
|
||||
if (!isLocal) //federation
|
||||
{
|
||||
|
|
@ -183,7 +183,7 @@ public class Requests
|
|||
|
||||
string targetId = serializedBody.string1;
|
||||
bool isUserLocal = Account.Utils.IsUserLocal(targetId, out string domain);
|
||||
string id2 = Account.Utils.GetIdFromUsernameWD(targetId);
|
||||
string id2 = Account.Utils.GetValidIdOrZero(targetId);
|
||||
|
||||
if (id2 == "0" || string.IsNullOrEmpty(id2))
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue