Logic Machine Forum
Push telegram not working on every object - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8)
+--- Thread: Push telegram not working on every object (/showthread.php?tid=4323)



Push telegram not working on every object - Alexander - 25.10.2022

Hi, I am trying to get push notifications with Telegram and for some objects it is working just fine.
But now I get this error on one specific object.

This script work just fine with another object.

What could be the problem?


RE: Push telegram not working on every object - admin - 25.10.2022

event.getvalue() returns Boolean for 1 bit object, not a number. So your comparison does not work and message is empty (nil). Use this instead:
Code:
value = event.getvalue()

if value then
  message = 'something is on'
else
  message = 'something is off'
end



RE: Push telegram not working on every object - Alexander - 25.10.2022

That was it.. Thank you for the quick reply!