mirror of
				https://gitlab.com/comunic/comunicmobile
				synced 2025-11-04 12:14:11 +00:00 
			
		
		
		
	Ready to pre-configure independent notifications service
This commit is contained in:
		@@ -1,3 +1,4 @@
 | 
			
		||||
import 'package:comunic/helpers/independent_push_notifications_helper.dart';
 | 
			
		||||
import 'package:comunic/helpers/push_notifications_helper.dart';
 | 
			
		||||
import 'package:comunic/helpers/server_config_helper.dart';
 | 
			
		||||
import 'package:comunic/models/config.dart';
 | 
			
		||||
@@ -15,8 +16,7 @@ import 'package:flutter/material.dart';
 | 
			
		||||
Future<void> showInitialPushNotificationsConfiguration(
 | 
			
		||||
    BuildContext context) async {
 | 
			
		||||
  // Check if no notifications service are available
 | 
			
		||||
  if (!PushNotificationsHelper.arePushNotificationsAvailable)
 | 
			
		||||
    return;
 | 
			
		||||
  if (!PushNotificationsHelper.arePushNotificationsAvailable) return;
 | 
			
		||||
 | 
			
		||||
  await Navigator.of(context).push(
 | 
			
		||||
      MaterialPageRoute(builder: (c) => PushNotificationsConfigurationRoute()));
 | 
			
		||||
@@ -118,9 +118,9 @@ class _PushNotificationsConfigurationRouteState
 | 
			
		||||
          // TODO: Handle this case.
 | 
			
		||||
          throw new Exception("Firebase not supported yet!");
 | 
			
		||||
          break;
 | 
			
		||||
 | 
			
		||||
        case PushNotificationsStatus.INDEPENDENT:
 | 
			
		||||
          // TODO: Handle this case.
 | 
			
		||||
          throw new Exception("Independent not supported yet!");
 | 
			
		||||
          await IndependentPushNotificationsHelper.preConfigure();
 | 
			
		||||
          break;
 | 
			
		||||
 | 
			
		||||
        default:
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user