mirror of
https://github.com/pyrogram/pyrogram
synced 2025-08-31 06:16:06 +00:00
Use "with" context manager in examples
This commit is contained in:
@@ -35,12 +35,9 @@ Example:
|
||||
password="password" # (if you have one)
|
||||
)
|
||||
|
||||
app.start()
|
||||
|
||||
with app:
|
||||
print(app.get_me())
|
||||
|
||||
app.stop()
|
||||
|
||||
Sign Up
|
||||
-------
|
||||
|
||||
@@ -67,8 +64,5 @@ Example:
|
||||
last_name="" # Can be an empty string
|
||||
)
|
||||
|
||||
app.start()
|
||||
|
||||
with app:
|
||||
print(app.get_me())
|
||||
|
||||
app.stop()
|
Reference in New Issue
Block a user