Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 957c351c authored by Philipp Heckel's avatar Philipp Heckel
Browse files

Switch to ~control for control channel

parent 58b56383
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -157,6 +157,9 @@ class ApiService {

    companion object {
        private const val TAG = "NtfyApiService"

        // These constants have corresponding values in the server codebase!
        const val CONTROL_TOPIC = "~control"
        const val EVENT_MESSAGE = "message"
        const val EVENT_KEEPALIVE = "keepalive"
    }
+1 −1
Original line number Diff line number Diff line
@@ -117,7 +117,7 @@ class MainActivity : AppCompatActivity(), ActionMode.Callback, AddFragment.Subsc
        notifier!!.createNotificationChannels()

        // Subscribe to control Firebase channel (so we can re-start the foreground service if it dies)
        messenger.subscribe("~keepalive")
        messenger.subscribe(ApiService.CONTROL_TOPIC)

        // Background things
        startPeriodicPollWorker()