mirror of
https://github.com/Sneed-Group/pypush-plus-plus
synced 2024-12-24 03:42:43 -06:00
don't hardcore username 🤣
This commit is contained in:
parent
50dd926559
commit
1fc7098d5a
1 changed files with 8 additions and 2 deletions
10
ids.py
10
ids.py
|
@ -421,12 +421,18 @@ class IDSUser:
|
||||||
KeyPair(self.push_connection.private_key, self.push_connection.cert),
|
KeyPair(self.push_connection.private_key, self.push_connection.cert),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
def __str__(self):
|
||||||
|
return f"IDSUser(user_id={self.user_id}, handles={self.handles}, push_token={b64encode(self.push_connection.token).decode()})"
|
||||||
|
|
||||||
|
|
||||||
def test():
|
def test():
|
||||||
|
import getpass
|
||||||
conn = apns.APNSConnection()
|
conn = apns.APNSConnection()
|
||||||
conn.connect()
|
conn.connect()
|
||||||
user = IDSUser(conn, "jjtech@jjtech.dev", "whiteCart25")
|
username = input("Enter username: ")
|
||||||
print(user.handles)
|
password = getpass.getpass("Enter password: ")
|
||||||
|
user = IDSUser(conn, username, password)
|
||||||
|
print(user)
|
||||||
# user.authenticate("test", "test")
|
# user.authenticate("test", "test")
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue