//package com.cloud.diplomaticquarterapp
package com.ejada.hmg

import io.flutter.plugin.common.PluginRegistry
//import io.flutter.plugins.firebasemessaging.FirebaseMessagingPlugin

object FirebaseCloudMessagingPluginRegistrant {
    fun registerWith(registry: PluginRegistry?) {
        if (alreadyRegisteredWith(registry)) {
            return
        }
      //  FirebaseMessagingPlugin.registerWith(registry?.registrarFor("io.flutter.plugins.firebasemessaging.FirebaseMessagingPlugin"))
    }

    private fun alreadyRegisteredWith(registry: PluginRegistry?): Boolean {
        val key: String? = FirebaseCloudMessagingPluginRegistrant::class.java.canonicalName
        if (key?.let { registry?.hasPlugin(it) }!!) {
            return true
        }
        if (registry != null) {
            registry.registrarFor(key)
        }
        return false
    }
}