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

Cannot GET /homeassistant//services #50

Closed
frenck opened this issue Dec 9, 2018 · 0 comments
Closed

Cannot GET /homeassistant//services #50

frenck opened this issue Dec 9, 2018 · 0 comments

Comments

@frenck
Copy link
Contributor

frenck commented Dec 9, 2018

Describe the bug

screen shot 2018-12-09 at 22 58 11

Solving issue #49 introduced a new issue, see screenshot above.

Caused by the following lines:

$.get(`homeassistant/${node.server}/entities`)

return $.get(`homeassistant/${node.server}/services`)

When there is no specific server node, the extra slash makes it an invalid URL for Hass.io.
The extra slash should only be included in case node.server actually has a value.

To Reproduce
Steps to reproduce the behavior:

  1. Add call service node

Expected behavior
Working stuff ;)

Screenshots
See opening post.

Example Flow
N/A

Environment (please complete the following information):

  • Node Red Version: 0.19.5
  • NR Home Assistant Plugin Version: 0.4.1
  • Is Node Red running in Docker: yes (Hass.io)

Other (please complete the following information):

  • Have you searched previous issues for duplicates?: Yes, see references.
  • Did you attempt to reproduce the issue in the dev docker environment, if so what were results (See README.md): Yes.

Additional context
N/A.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant