Automatic style fix

This commit is contained in:
robot-clickhouse 2024-09-26 12:14:32 +00:00
parent 45d190650f
commit d56cd41395

View File

@ -238,10 +238,12 @@ class SourceMongo(ExternalSource):
self.db = self.connection["test"]
user_info = self.db.command("usersInfo", self.user)
if user_info['users']:
if user_info["users"]:
self.db.command("updateUser", self.user, pwd=self.password)
else:
self.db.command("createUser", self.user, pwd=self.password, roles=["readWrite"])
self.db.command(
"createUser", self.user, pwd=self.password, roles=["readWrite"]
)
self.prepared = True
def load_data(self, data, table_name):