这就是我所拥有的:
@client.command(pass_context=True)
@client.event
async def on_member_join(ctx, member):
print(f'{member} has joined a server.')
await ctx.send(f"Hello {member}!")
await ctx.member.send(f"Welcome to the server!")
Run Code Online (Sandbox Code Playgroud)
我需要机器人在加入时发送包含规则和命令列表的私人消息。
请帮忙!
我如何从时间戳中减去一周firebase.firestore.Timestamp.now()?我有不同的带有时间戳的文档,我需要构建一个函数来检查这些文档中是否有任何文档的时间戳早于 7 天。哎呀,也许有一个内置函数可以检查日期是否“过期”?提前致谢。
javascript firebase google-cloud-functions google-cloud-firestore