Fix Missing 'mongodb'

This commit is contained in:
Alexander 2015-08-08 21:14:57 -04:00
parent 59b5db96f3
commit f6e34fd8a5

View file

@ -10,10 +10,10 @@ class LeaderboardMgrAI:
if not self.air.dbConn: if not self.air.dbConn:
self.database = simbase.backups.load('leaderboard', (self.air.districtId,), default=({})) self.database = simbase.backups.load('leaderboard', (self.air.districtId,), default=({}))
else: else:
self.air.mongodb.toontown.leaderboard.ensure_index([('ai', 1)]) self.air.dbGlobalCursor.leaderboard.ensure_index([('ai', 1)])
district = {'ai': self.air.districtId} district = {'ai': self.air.districtId}
try: try:
doc = self.air.mongodb.toontown.leaderboard.find_one(district) doc = self.air.dbGlobalCursor.leaderboard.find_one(district)
except AutoReconnect: except AutoReconnect:
return blocks return blocks