Skip to content

Commit

Permalink
fix friend gallery disappearing snsinfo
Browse files Browse the repository at this point in the history
  • Loading branch information
fkzhang committed Feb 5, 2016
1 parent bcd69e7 commit 372cce7
Showing 1 changed file with 0 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ protected void hookSns(final ClassLoader loader) {
mP.snsMethod, new XC_MethodHook() {
@Override
protected void afterHookedMethod(MethodHookParam param) throws Throwable {
log("hooked in wechat sns");
init(loader);
if (mSnsSQL == null) {
mSnsSQL = param.args[0];
Expand Down Expand Up @@ -177,10 +176,6 @@ protected void afterHookedMethod(MethodHookParam param) throws Throwable {

String s = ((String) param.args[0]).toLowerCase();

if (s.equalsIgnoreCase("snsinfo")) {
log("" + param.args[2]);
}

if (!s.equalsIgnoreCase("snscomment"))
return;

Expand Down Expand Up @@ -822,7 +817,6 @@ protected void unsetSnsDeleteFlag(ContentValues v) {
}

protected void setSnsDeleteFlag(ContentValues v) {
log(v.toString());
Object contentObject = decodeBlob(mSnsContentClass, v.getAsByteArray("content"));
if (contentObject == null)
return;
Expand All @@ -831,20 +825,10 @@ protected void setSnsDeleteFlag(ContentValues v) {

content = mSettings.getString("deleted", "[已删除]") + "\n" + content;
setObjectField(contentObject, mP.snsContentField, content);
log(content);

ContentValues c = new ContentValues();
c.put("content", encodeContentBlob(contentObject));
// if (v.getAsInteger("sourceType") != 0) {
c.put("sourceType", 10);
// }
// log(c.toString());

String query = "SELECT sourceType FROM SnsInfo WHERE snsId = '" + v.getAsString("snsId") + "'";
Cursor cursor = rawQuerySns(query);
XposedUtil.inspectCursor(cursor);
cursor.close();


updateSns("SnsInfo", c, "snsId = ?", new String[]{v.getAsString("snsId")});
}
Expand Down

0 comments on commit 372cce7

Please sign in to comment.