Update the style of messages.
This commit is contained in:
@@ -53,9 +53,9 @@ class ProducerClient:
|
||||
|
||||
try:
|
||||
while True:
|
||||
print('Your notification: ')
|
||||
title = input('title: ')
|
||||
message = input('message: ')
|
||||
self.console.print('\n[cyan b]Your notification[/]: ')
|
||||
title = Prompt.ask('[cyan]title[/]')
|
||||
message = Prompt.ask('[cyan]message[/]')
|
||||
await self.send_notification(title, message)
|
||||
|
||||
if title == '' and message == '':
|
||||
@@ -66,8 +66,8 @@ class ProducerClient:
|
||||
except asyncio.CancelledError:
|
||||
pass
|
||||
except KeyboardInterrupt:
|
||||
print("\nbye")
|
||||
await self.send_notification('', '')
|
||||
self.console.print("\n[green]bye[/]")
|
||||
sys.exit(0)
|
||||
finally:
|
||||
self.writer.close()
|
||||
|
||||
Reference in New Issue
Block a user