Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd event default value to 0 #2990

Closed
wants to merge 1 commit into from
Closed

Conversation

Salvialf
Copy link
Contributor

@Salvialf Salvialf commented Dec 3, 2024

Description

Set a default value (0) for $cmd->event() function

Related issues/external references

Fixes #2989

Types of changes

  • Bug fix (non-breaking change which fixes)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
    • This change is only breaking for integrators, not for external standards or end-users.
  • Documentation improvement

@Salvialf Salvialf linked an issue Dec 3, 2024 that may be closed by this pull request
@Salvialf Salvialf closed this Dec 3, 2024
@Salvialf Salvialf deleted the cmd-event-default-value branch December 3, 2024 20:15
@Salvialf Salvialf restored the cmd-event-default-value branch December 3, 2024 20:21
@Salvialf Salvialf reopened this Dec 3, 2024
@Salvialf
Copy link
Contributor Author

Salvialf commented Dec 3, 2024

not sure, default value may be empty string too...

@Mips2648
Copy link
Collaborator

Mips2648 commented Dec 4, 2024

indeed, i wouldn't do that blindly on all events
what could be done potentially is to force 0 or 1 if binary command, so forbid empty or null value
but even if this seems to make sense, this could be a "breaking change" if some users or plugins took advantage of this "flexibility"

@Salvialf
Copy link
Contributor Author

Salvialf commented Dec 4, 2024

Thanks for your comment.

Did some test yesterday evening and had an error Too few arguments to function cmd::event() with $cmd->event(jeedom::evaluateExpression(false));

Tested again now with no error so it must be that i made a mistake in my tests yesterday.

You're totally right, closing issue. Thanks again

@Salvialf Salvialf closed this Dec 4, 2024
@Salvialf Salvialf deleted the cmd-event-default-value branch December 4, 2024 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

cmd event default value
2 participants