Renamed encryption/other_accounts into encryption/accounts
This commit is contained in:
parent
281c4a262b
commit
5d59adb7d2
@ -307,7 +307,7 @@ async def _add_account5(
|
|||||||
password=data["passwd"],
|
password=data["passwd"],
|
||||||
)
|
)
|
||||||
|
|
||||||
encrypted_account = encryption.other_accounts.encrypt(
|
encrypted_account = encryption.accounts.encrypt(
|
||||||
account,
|
account,
|
||||||
text,
|
text,
|
||||||
)
|
)
|
||||||
@ -393,7 +393,7 @@ async def _get_account3(
|
|||||||
)
|
)
|
||||||
|
|
||||||
account = database.get.get_account_info(engine, mes.from_user.id, name)
|
account = database.get.get_account_info(engine, mes.from_user.id, name)
|
||||||
account = encryption.other_accounts.decrypt(
|
account = encryption.accounts.decrypt(
|
||||||
account,
|
account,
|
||||||
text,
|
text,
|
||||||
)
|
)
|
||||||
@ -541,7 +541,9 @@ async def _export2(
|
|||||||
tasks = []
|
tasks = []
|
||||||
for account in accounts:
|
for account in accounts:
|
||||||
function = functools.partial(
|
function = functools.partial(
|
||||||
encryption.other_accounts.decrypt, account, text
|
encryption.accounts.decrypt,
|
||||||
|
account,
|
||||||
|
text,
|
||||||
)
|
)
|
||||||
tasks.append(loop.run_in_executor(pool, function))
|
tasks.append(loop.run_in_executor(pool, function))
|
||||||
accounts = await asyncio.gather(*tasks)
|
accounts = await asyncio.gather(*tasks)
|
||||||
@ -649,7 +651,7 @@ async def _import3(
|
|||||||
if not check_account(account):
|
if not check_account(account):
|
||||||
failed.append(account.name)
|
failed.append(account.name)
|
||||||
continue
|
continue
|
||||||
account = encryption.other_accounts.encrypt(
|
account = encryption.accounts.encrypt(
|
||||||
account,
|
account,
|
||||||
text,
|
text,
|
||||||
)
|
)
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
from . import master_pass, other_accounts
|
from . import accounts, master_pass
|
||||||
|
|
||||||
__all__ = ["master_pass", "other_accounts"]
|
__all__ = ["master_pass", "accounts"]
|
||||||
|
Reference in New Issue
Block a user