Skip to content

Commit

Permalink
Fixes a another potential comparison issue that I missed from my last…
Browse files Browse the repository at this point in the history
… commit.
  • Loading branch information
allebb committed Jun 13, 2019
1 parent 7075f79 commit 2fc47e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Adapters/RPiAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public function setDirection(int $pin, string $direction, bool $invert = false):

if ($invert) {
$inverted = intval($invert);
if (file_get_contents("/sys/class/gpio/gpio{$pin}/active_low") !== $inverted) {
if (file_get_contents("/sys/class/gpio/gpio{$pin}/active_low") != $inverted) {
system("echo {$inverted} > /sys/class/gpio/gpio{$pin}/active_low");
}
}
Expand Down

0 comments on commit 2fc47e6

Please sign in to comment.