diff --git a/lib/providers/notification.dart b/lib/providers/notification.dart index 8475618..f4b151c 100644 --- a/lib/providers/notification.dart +++ b/lib/providers/notification.dart @@ -25,6 +25,7 @@ class NotificationProvider extends ChangeNotifier { if (!_ua.isAuthorized) return; log("Registering push notifications..."); await registerPushNotifications(); + log("Registered push notification subscriber successfully!"); }); } @@ -54,7 +55,7 @@ class NotificationProvider extends ChangeNotifier { log('Device Push Token is $token'); await _sn.client.post( - '/cgi/id/notifications/subscribe', + '/cgi/id/notifications/subscription', data: { 'provider': provider, 'device_token': token, diff --git a/lib/widgets/chat/chat_message_input.dart b/lib/widgets/chat/chat_message_input.dart index 04c7301..d372a08 100644 --- a/lib/widgets/chat/chat_message_input.dart +++ b/lib/widgets/chat/chat_message_input.dart @@ -275,6 +275,8 @@ class ChatMessageInputState extends State { ]), border: InputBorder.none, ), + onTapOutside: (_) => + FocusManager.instance.primaryFocus?.unfocus(), onSubmitted: (_) { if (_isBusy) return; _sendMessage();