Skip to content

Commit

Permalink
v2.3.0-alpha.2
Browse files Browse the repository at this point in the history
  • Loading branch information
fracz committed Oct 10, 2017
1 parent 319728d commit 30e107e
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 13 deletions.
11 changes: 0 additions & 11 deletions backend/models/voice/FeedbackInterpolator.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,6 @@ public function interpolate(string $feedback)
return preg_replace_callback('#{{(\d+)\|(on|temperature|humidity|hi)\|(bool|number):?(.+?)?}}#', function ($match) {
$replacement = $this->replaceChannelState($match[1], $match[2], $match[3], explode(',', $match[4]));
return $replacement ?: $match[0];
// $variable = $match[1];
// $resultIndex = isset($match[2]) && $match[2] ? $match[2] : 0;
// $value = $results[$resultIndex]->{$variable};
// if ($variable == 'on') {
// $value = $value ? 'włączone' : 'wyłączone';
// } else if ($variable == 'hi') {
// $value = $value ? 'zamknięta' : 'otwarta';
// } else if (floatval($value)) {
// $value = number_format($value, 1, ',', '');
// }
// return $value;
}, $feedback);
}

Expand Down
2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "supla-scripts",
"version": "2.3.0-alpha.1",
"version": "2.3.0-alpha.2",
"private": true,
"license": "UNLICENSED",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "supla-scripts",
"version": "2.3.0-alpha.1",
"version": "2.3.0-alpha.2",
"description": "",
"license": "UNLICENSED",
"private": true,
Expand Down

0 comments on commit 30e107e

Please sign in to comment.