mirror of
https://github.com/SantaSpeen/anixart.git
synced 2026-04-03 06:26:01 +00:00
[+] AnixartAccountSaved
This commit is contained in:
@@ -1 +1 @@
|
||||
from .account import AnixartAccount, AnixartAccountToken
|
||||
from .account import AnixartAccount, AnixartAccountSaved, AnixartAccountToken
|
||||
|
||||
@@ -28,14 +28,14 @@ class AnixartAccount:
|
||||
def token(self):
|
||||
return self._token
|
||||
|
||||
def to_file(self, filename: str | Path):
|
||||
def to_file(self, filename: str | Path) -> "AnixartAccountSaved":
|
||||
"""Save the account information to a file."""
|
||||
acc = AnixartAccountSaved.from_account(filename, self)
|
||||
acc.save()
|
||||
return acc
|
||||
|
||||
@classmethod
|
||||
def from_file(cls, filename: str | Path):
|
||||
def from_file(cls, filename: str | Path) -> "AnixartAccountSaved":
|
||||
"""Load the account information from a file."""
|
||||
acc = AnixartAccountSaved(filename)
|
||||
acc.load()
|
||||
|
||||
Reference in New Issue
Block a user