File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
app/src/main/java/com/wmods/wppenhacer/xposed/core/devkit Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -1114,13 +1114,13 @@ public synchronized static Field loadSetEditMessageField(ClassLoader loader) thr
11141114 */
11151115 public synchronized static Method loadEditMessageShowMethod (ClassLoader loader ) throws Exception {
11161116 return UnobfuscatorCache .getInstance ().getMethod (loader , () -> {
1117- var clazz = findFirstClassUsingStrings (loader , StringMatchType .Contains , "newsletter_reaction_sheet" );
1118- var fields = Arrays .stream (clazz .getDeclaredFields ()).filter (f -> f .getType ().equals (TextView .class )).toArray (Field []::new );
1119- var classData = dexkit .getClassData (clazz );
1120- if (fields .length == 0 ) throw new RuntimeException ("EditMessageShow method not found" );
1117+ var classData = dexkit .findClass (FindClass .create ().matcher (ClassMatcher .create ().addUsingString ("ConversationRow/setUpUsernameInGroupView" ))).singleOrNull ();
1118+ var fields = classData .getFields ().stream ().filter (f -> f .getType ().getName ().equals (TextView .class .getName ())).collect (Collectors .toList ());
1119+ if (fields .isEmpty ()) throw new RuntimeException ("EditMessageShow fields not found" );
11211120 for (var field : fields ) {
1122- var result = dexkit .findMethod (new FindMethod ().matcher (new MethodMatcher ().addUsingField (DexSignUtil .getFieldDescriptor (field )).paramCount (1 )).searchInClass (List .of (classData )));
1123- if (!result .isEmpty ()) return result .get (0 ).getMethodInstance (loader );
1121+ var result = classData .findMethod (FindMethod .create ().matcher (MethodMatcher .create ().addUsingField (field .getDescriptor ()).paramCount (1 ))).singleOrNull ();
1122+ if (result != null )
1123+ return result .getMethodInstance (loader );
11241124 }
11251125 throw new RuntimeException ("EditMessageShow method not found" );
11261126 });
You can’t perform that action at this time.
0 commit comments