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

ReferenceError: callback is not defined #9

Closed
HorstBaerbel opened this issue Jan 25, 2020 · 4 comments
Closed

ReferenceError: callback is not defined #9

HorstBaerbel opened this issue Jan 25, 2020 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@HorstBaerbel
Copy link

When CEC is used, due to naming error:

turnOnCEC: function(commandCallback,queueCallback) {
exec('echo "on 0" | cec-client ' + this.config.comport + ' -s -d 1', callback);

@nischi nischi closed this as completed in dceb30e Jan 27, 2020
@ericlo00
Copy link

ericlo00 commented Mar 8, 2020

Is this fixed? I seem to still get the same callback error using CECControl. Btw, I'm using the latest node_helper.js.

[22:41:51.909] [LOG]    CECControl change status (current, new): none on
[22:41:51.911] [LOG]    Whoops! There was an uncaught exception...
[22:41:51.911] [ERROR]  ReferenceError: callback is not defined
    at Class.turnOnCEC (/home/pi/MagicMirror/modules/MMM-CECControl/node_helper.js:70:72)
    at Class.turnOn (/home/pi/MagicMirror/modules/MMM-CECControl/node_helper.js:99:9)
    at Class.handleQueue (/home/pi/MagicMirror/modules/MMM-CECControl/node_helper.js:33:13)
    at Class.socketNotificationReceived (/home/pi/MagicMirror/modules/MMM-CECControl/node_helper.js:64:10)
    at Socket.<anonymous> (/home/pi/MagicMirror/js/node_helper.js:113:11)
    at Socket.emit (events.js:200:13)
    at /home/pi/MagicMirror/node_modules/socket.io/lib/socket.js:528:12
    at processTicksAndRejections (internal/process/task_queues.js:82:9)

@nischi
Copy link
Owner

nischi commented Mar 9, 2020

i need to check that on my machine shortly. will get some feedback.

@nischi nischi reopened this Mar 9, 2020
@nischi nischi added the bug Something isn't working label Mar 9, 2020
@nischi nischi self-assigned this Mar 9, 2020
@HorstBaerbel
Copy link
Author

HorstBaerbel commented Mar 14, 2020

@nischi Not a node.js expert, but you might need to update package-lock.json to the new version number (1.4). I update the version in package.json, but not in package-lock.json.

@nischi
Copy link
Owner

nischi commented Mar 15, 2020

@HorstBaerbel package-lock.json is a generated file and you should not update it manually. Its anyway not needed if you do a npm install, only if you use npm ci. So that do no difference but should be the same.

@nischi nischi closed this as completed Oct 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants