From 3fcff9803e910ad43ade1060ea7ed6a4a3f1d0ca Mon Sep 17 00:00:00 2001 From: Bandie Date: Mon, 18 Jan 2021 20:51:33 +0100 Subject: [PATCH] Path to status.json in config --- config.php | 1 + update.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/config.php b/config.php index b6fdc9f..8a64319 100644 --- a/config.php +++ b/config.php @@ -2,3 +2,4 @@ $active = false; $consumer_key = 'asdf'; $consumer_secret = 'qwer'; +$statusJSONFile = '../status.json'; diff --git a/update.php b/update.php index 926dcd8..59ce640 100644 --- a/update.php +++ b/update.php @@ -107,7 +107,7 @@ if(!$status["sensors"]["door_locked"][0]["value"] || !$status["sensors"]["door_l $json = json_encode($status); // Write this shit -file_put_contents("../status.json", $json); +file_put_contents($statusJSONFile, $json); // Show what we've done! echo($json);