fix (voice): Remove transaction.
This commit is contained in:
@@ -162,19 +162,18 @@ class VoiceSession:
|
|||||||
)
|
)
|
||||||
|
|
||||||
conn = await self.bot.db.get_connection()
|
conn = await self.bot.db.get_connection()
|
||||||
async with conn.transaction():
|
# Insert an ongoing_session with the correct state, set data
|
||||||
# Insert an ongoing_session with the correct state, set data
|
state = self.state
|
||||||
state = self.state
|
self.data = await self.registry.VoiceSessionsOngoing.create(
|
||||||
self.data = await self.registry.VoiceSessionsOngoing.create(
|
guildid=self.guildid,
|
||||||
guildid=self.guildid,
|
userid=self.userid,
|
||||||
userid=self.userid,
|
channelid=state.channelid,
|
||||||
channelid=state.channelid,
|
start_time=start_time,
|
||||||
start_time=start_time,
|
last_update=start_time,
|
||||||
last_update=start_time,
|
live_stream=state.stream,
|
||||||
live_stream=state.stream,
|
live_video=state.video,
|
||||||
live_video=state.video,
|
hourly_coins=self.hourly_rate
|
||||||
hourly_coins=self.hourly_rate
|
)
|
||||||
)
|
|
||||||
self.bot.dispatch('voice_session_start', self.data)
|
self.bot.dispatch('voice_session_start', self.data)
|
||||||
self.start_task = None
|
self.start_task = None
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user