forked from distok/cutthecord
parent
4bf12e1e2b
commit
1066c3c5a6
1 changed files with 70 additions and 0 deletions
|
@ -1,3 +1,73 @@
|
|||
diff -crB com.discord-970-base/smali_classes2/okhttp3/MultipartBody$Part.smali com.discord-970/smali_classes2/okhttp3/MultipartBody$Part.smali
|
||||
*** com.discord-970-base/smali_classes2/okhttp3/MultipartBody$Part.smali 2019-10-10 08:36:54.670388010 +0300
|
||||
--- com.discord-970/smali_classes2/okhttp3/MultipartBody$Part.smali 2019-10-10 08:48:52.678274615 +0300
|
||||
***************
|
||||
*** 43,50 ****
|
||||
return-void
|
||||
.end method
|
||||
|
||||
.method public static a(Ljava/lang/String;Ljava/lang/String;Lokhttp3/RequestBody;)Lokhttp3/MultipartBody$Part;
|
||||
! .locals 2
|
||||
.param p1 # Ljava/lang/String;
|
||||
.annotation runtime Ljavax/annotation/Nullable;
|
||||
.end annotation
|
||||
--- 43,84 ----
|
||||
return-void
|
||||
.end method
|
||||
|
||||
+ .method public static final interceptFilename(Ljava/lang/String;)Ljava/lang/String;
|
||||
+ .locals 3
|
||||
+
|
||||
+ invoke-static {}, Lcom/discord/stores/StoreStream;->getUserSettings()Lcom/discord/stores/StoreUserSettings;
|
||||
+
|
||||
+ move-result-object v0
|
||||
+
|
||||
+ invoke-virtual {v0}, Lcom/discord/stores/StoreUserSettings;->getImageSpoiler()Z
|
||||
+
|
||||
+ move-result v1
|
||||
+
|
||||
+ if-eqz v1, :cond_1
|
||||
+
|
||||
+ new-instance v2, Ljava/lang/StringBuilder;
|
||||
+
|
||||
+ const-string v1, "SPOILER_"
|
||||
+
|
||||
+ invoke-direct {v2, v1}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
||||
+
|
||||
+ invoke-virtual {v2, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
+
|
||||
+ invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
||||
+
|
||||
+ move-result-object p0
|
||||
+
|
||||
+ # I commented this out and do this in StoreMessages now as this'd only work for a single image
|
||||
+ # const/4 v1, 0x0
|
||||
+
|
||||
+ # invoke-virtual {v0, v1}, Lcom/discord/stores/StoreUserSettings;->setImageSpoiler(Z)V
|
||||
+
|
||||
+ :cond_1
|
||||
+ return-object p0
|
||||
+ .end method
|
||||
+
|
||||
.method public static a(Ljava/lang/String;Ljava/lang/String;Lokhttp3/RequestBody;)Lokhttp3/MultipartBody$Part;
|
||||
! .locals 5
|
||||
.param p1 # Ljava/lang/String;
|
||||
.annotation runtime Ljavax/annotation/Nullable;
|
||||
.end annotation
|
||||
***************
|
||||
*** 69,74 ****
|
||||
--- 103,113 ----
|
||||
.line 255
|
||||
invoke-virtual {v0, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
|
||||
+ invoke-static {p1}, Lokhttp3/MultipartBody$Part;->interceptFilename(Ljava/lang/String;)Ljava/lang/String;
|
||||
+
|
||||
+ move-result-object p1
|
||||
+
|
||||
+ :cond_2
|
||||
.line 256
|
||||
invoke-static {v0, p1}, Lokhttp3/MultipartBody;->a(Ljava/lang/StringBuilder;Ljava/lang/String;)Ljava/lang/StringBuilder;
|
||||
|
||||
diff -crB com.discord-992-base/smali/com/discord/gateway/io/IncomingParser.smali com.discord-992/smali/com/discord/gateway/io/IncomingParser.smali
|
||||
*** com.discord-992-base/smali/com/discord/gateway/io/IncomingParser.smali 2019-11-26 10:48:45.866158214 +0300
|
||||
--- com.discord-992/smali/com/discord/gateway/io/IncomingParser.smali 2019-11-26 16:10:19.603520324 +0300
|
||||
|
|
Loading…
Reference in a new issue