fix(SlashCommandsFix): 8.18.0 - don't use new props

This commit is contained in:
Cilly Leang 2025-08-18 01:44:39 +10:00
parent c683db2a0b
commit 05a76ff7ac
Signed by: cilly
GPG key ID: 6500251E087653C9
2 changed files with 4 additions and 11 deletions

View file

@ -273,19 +273,9 @@ final class Patches {
var applicationIndex = source.getFromCache(applicationIndexCache);
if (!applicationIndex.isPresent()) {
try {
var versionCode = 218111;
var versionString = "218.11 - rn";
var userAgent = "Discord-Android/218111;RNA";
var props = RNSuperProperties.getSuperProperties()
.put("client_version", versionString)
.put("client_build_number", versionCode);
var props64 = Base64.encodeToString(props.toString().getBytes(), 2);
// Request application index from API
applicationIndex = Optional.of(
Http.Request.newDiscordRNRequest(source.getEndpoint())
.setHeader("User-Agent", userAgent)
.setHeader("X-Super-Properties", props64)
.execute()
.json(GsonUtils.getGsonRestApi(), ApiApplicationIndex.class)
.toModel()