Skip to content

A msg.warning of 0 doesn't override the GUI setting to cancel sending a warning message #23

Description

@linuxha

A msg.warning of 0 doesn't override the GUI setting to cancel sending a warning message
If I send a message like this:
{ "payload": "on", "timeout": 4, "warning": 0 }
I still get the warning message sent on first output
{ "payload":"warn" }
The problem is being investigated

Activity

  1. self-assigned this
    on Oct 13, 2019
  2. linuxha commented on Oct 13, 2019

    @linuxha
    OwnerAuthor

    This works:
    {"payload": "on", "timeout": 3, "warning": "0" }
    But this does not:
    {"payload": "on", "timeout": 3, "warning": 0 }
    I'll fix the code to accept both integer and string forms.

  3. marc-gist commented on Dec 29, 2020

    @marc-gist

    Still seems to be an issue when setting from the GUI. Unless you also set the "Warning state payload" to nothing (blank). Otherwise the warning set to 0 in the GUI is ignored and the warning payload is sent at 5 seconds.

  4. linuxha commented on Jan 3, 2021

    @linuxha
    OwnerAuthor

    Okay, I think I see the problem:

    node.warnT = parseInt(n.warning)||5;// node-input-warning - time in seconds (?)

    I'll need to change the logic and probably the documentation. With what I have if it's set to 0 in the GUI, the warning gets set to 5 seconds. I'll need to figure out what the default should be and adjust accordingly.

    Thanks for finding that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions