From 4eef8753c133caf833e50858dd77963035d4e2d1 Mon Sep 17 00:00:00 2001 From: JonatanRek Date: Wed, 9 Oct 2019 10:59:47 +0200 Subject: [PATCH] ServerKeyToConfig --- app/class/AutomationManager.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/app/class/AutomationManager.php b/app/class/AutomationManager.php index 80264b5..76d7935 100644 --- a/app/class/AutomationManager.php +++ b/app/class/AutomationManager.php @@ -106,7 +106,6 @@ class AutomationManager{ //finalization if ($run) { - $serverKey = 'AAAAFcN4elo:APA91bG4GViYbiwDHhNgkcOc3DpCYHW_4dpj9F-nQ-v5yiRcps9iENT6CmVAi8Qxxyjid5mrsMAqib9YSyObBOEJLg-Q9gsD5MnVaJjjTYggwyeyJEgFLM5wQNPeqQDPvIecXS9sbib4'; $body = ''; $sceneDoArray = json_decode($sceneDoJson); @@ -118,10 +117,10 @@ class AutomationManager{ $i = 0; foreach ($subscribers as $key => $subscriber) { $logManager->write("[NOTIFICATION] SENDING NOTIFICATION TO" . $subscriber['id'] . " was executed" . $i); - $title = 'Automatizace-'.$automation['automation_id']." was executed" . $i; - $notification = new Notification($serverKey); + $title = 'Automatization '.$automation['name']." was just executed"; + $notification = new Notification(SERVERKEY); $notification->to($subscriber['token']); - $notification->notification($subscriber['id'], '' , '', ''); + $notification->notification($title, '' , '', ''); $notification->send(); $notification = null; }