Skip to content

Commit

Permalink
Merge pull request pihome-shc#334 from twa127/master
Browse files Browse the repository at this point in the history
Fix for bug in db.php introduced in last commit
  • Loading branch information
pihome-shc authored Jul 16, 2020
2 parents 725cfd6 + d252d99 commit 2c04f7a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion db.php
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@
$node_name = $_GET['node_name'];
$notice_interval = $_GET['notice_interval'];
//Add record to Nodes table
$query = "INSERT INTO `nodes`(`sync`, `purge`, `type`, `node_id`, `max_child_id`, `name`, `last_seen`, `notice_interval`, `min_voltage`, `status`, `ms_version`, `sketch_version`, `repeater`) VALUES ('0', '0', '{$node_type}', '{$node_id}', '{$node_child_id}', '{$node_name}', '{$datetime}', '{$notice_interval}', '0', 'Active', '0', '0', '0')";
$query = "INSERT INTO `nodes`(`sync`, `purge`, `type`, `node_id`, `max_child_id`, `name`, `last_seen`, `notice_interval`, `min_value`, `status`, `ms_version`, `sketch_version`, `repeater`) VALUES ('0', '0', '{$node_type}', '{$node_id}', '{$node_child_id}', '{$node_name}', '{$datetime}', '{$notice_interval}', '0', 'Active', '0', '0', '0')";
if($conn->query($query)){
header('Content-type: application/json');
echo json_encode(array('Success'=>'Success','Query'=>$query));
Expand Down

0 comments on commit 2c04f7a

Please sign in to comment.