redis临时修复

This commit is contained in:
dy 2023-12-25 20:54:59 +08:00
parent 080665f24e
commit 0e08958202
2 changed files with 27 additions and 26 deletions

View File

@ -1,21 +1,20 @@
import { PeiJian } from '../shared/protocols/peijian/PtlGetList'; import {PeiJian} from '../shared/protocols/peijian/PtlGetList';
import { CollectionDxlt } from './collection_dxlt'; import {CollectionDxlt} from './collection_dxlt';
import { CollectionEmail } from './collection_email'; import {CollectionEmail} from './collection_email';
import { CollectionEquip } from './collection_equip'; import {CollectionEquip} from './collection_equip';
import { CollectionFightLog } from './collection_fightLog'; import {CollectionFightLog} from './collection_fightLog';
import { CollectionGBTX } from './collection_gbtx'; import {CollectionGBTX} from './collection_gbtx';
import { CollectionHero } from './collection_hero'; import {CollectionHero} from './collection_hero';
import { CollectionItem } from './collection_item'; import {CollectionItem} from './collection_item';
import { CollectionJJC } from './collection_jjc'; import {CollectionJJC} from './collection_jjc';
import { CollectionShiwu } from './collection_shiwu'; import {CollectionShiwu} from './collection_shiwu';
import { CollectionShop } from './collection_shop'; import {CollectionShop} from './collection_shop';
import { CollectionTanXian } from './collection_tanxian'; import {CollectionTanXian} from './collection_tanxian';
import { CollectionUser } from './collection_user'; import {CollectionUser} from './collection_user';
import {payLog} from '../shared/protocols/pay/PtlGetList'; import {payLog} from '../shared/protocols/pay/PtlGetList';
import { rankInfo } from '../shared/protocols/type'; import {rankInfo} from '../shared/protocols/type';
import { CollectionFriend } from '../module/collection_friend'; import {CollectionFriend} from '../module/collection_friend';
import { CollectionGongHui } from '../module/collection_gonghui'; import {CollectionGongHui} from '../module/collection_gonghui';
export type sortEd = { export type sortEd = {
@ -29,7 +28,7 @@ export type sortEd = {
export type RedisCollections1 = { export type RedisCollections1 = {
user: CollectionUser; user: CollectionUser;
gbtx: CollectionGBTX; gbtx: CollectionGBTX;
tanxian: Omit<CollectionTanXian, 'fastGuaJiNum'>; tanxian: Omit<CollectionTanXian, 'fastGuaJiNum'> | any;
dxlt: CollectionDxlt; dxlt: CollectionDxlt;
jjc: CollectionJJC; jjc: CollectionJJC;
}; };

View File

@ -19,14 +19,16 @@ export async function clearGud(uid) {
G.ioredis.del(`gudVersion:${uid}_ver`); G.ioredis.del(`gudVersion:${uid}_ver`);
} }
if(await G.redis.type('tanxian', uid)){ if (await G.redis.type('tanxian', uid)) {
console.log('清空tanxian Redis',uid); console.log('清空tanxian Redis', uid);
G.redis.del("tanxian",uid); // G.redis.del("tanxian", uid);
G.redis.set('tanxian', uid, {})
} }
try{ try {
console.log('清空friend:list Redis',uid); // console.log('清空friend:list Redis', uid);
G.redis.hDel("friend:list",uid); // G.redis.hDel("friend:list", uid);
}catch(e){ // G.redis.hSet('friend:list', uid, {})
} catch (e) {
} }
}; };