1
0
Fork 0
mirror of https://codeberg.org/demostf/plugin.git synced 2026-06-04 00:54:08 +02:00

Merge pull request #9 from TheBv/master

Fixed issues with handling responses that don't link to the STV
This commit is contained in:
Robin Appelman 2022-12-23 19:19:32 +01:00 committed by GitHub
commit 62f7dc8fc6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 13 deletions

Binary file not shown.

View file

@ -7,7 +7,7 @@ public Plugin:myinfo =
name = "demos.tf uploader", name = "demos.tf uploader",
author = "Icewind", author = "Icewind",
description = "Auto-upload match stv to demos.tf", description = "Auto-upload match stv to demos.tf",
version = "0.3", version = "0.3.1",
url = "https://demos.tf" url = "https://demos.tf"
}; };
@ -164,6 +164,8 @@ public ShowResponse()
strcopy(url, sizeof(url), output); strcopy(url, sizeof(url), output);
if (StrContains(url, "STV available at: ") != -1)
{
// Get the url part // Get the url part
ReplaceString(url, sizeof(url), "STV available at: ", ""); ReplaceString(url, sizeof(url), "STV available at: ", "");
// Split the string on '/' // Split the string on '/'
@ -177,9 +179,11 @@ public ShowResponse()
break; break;
} }
} }
CallDemoUploaded(true, demoid, url); CallDemoUploaded(true, demoid, url);
return;
}
CallDemoUploaded(false, "", "");
return; return;
} }