Skip to content

Commit

Permalink
fix bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
hidetak committed Mar 22, 2024
1 parent dd64c37 commit e9f6f0a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
7 changes: 5 additions & 2 deletions node-red-node-wot/src/wot-thing-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,14 @@ module.exports = function (RED) {
RED.nodes.createNode(this, config)
const node = this
node.getProps = () => {
return {
let props = {
title: config.name,
description: config.description,
id: config.thingId,
}
if (config.thingId) {
props["id"] = config.thingId
}
return props
}
node.getCredentials = () => {
return {
Expand Down
2 changes: 1 addition & 1 deletion node-red-node-wot/src/wot-update-td.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
if (this.name) {
return this.name
} else {
return "Update-TD"
return "update-TD"
}
},
oneditprepare: function () {
Expand Down
1 change: 0 additions & 1 deletion node-red-node-wot/src/wot-update-td.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ module.exports = function (RED) {
if (config.tdSource && config.tdSourceType) {
try {
td = await RED.util.evaluateNodeProperty(config.tdSource, config.tdSourceType, node, msg)
console.log("*** update td:", td)
} catch (err) {
return done("cannot evaluate td source")
}
Expand Down

0 comments on commit e9f6f0a

Please sign in to comment.