Update get.js

This commit is contained in:
Tyler Cooper 2025-08-07 15:42:24 -05:00 committed by GitHub
parent 4b2b8705f7
commit b24bed02ed
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -4,21 +4,18 @@ export default {
bytecodeKey: "getVariable",
name: "Get Variable",
colour: 240,
description: "Get the value previously assigned to a variable.",
description: "Retrieve the value stored in a variable that was previously set using a Set Variable block. Use this to access stored feed values, calculation results, or any data saved earlier in your Action.",
connections: {
mode: 'value',
output: "expression",
},
template: "Get variable %VAR",
fields: {
VAR: {
description: "Select the variable name whose value you want to retrieve. The variable must have been created and assigned a value earlier in your Action using a Set Variable block.",
type: 'field_variable'
}
},
generators: {
json: block => {
const
@ -28,17 +25,14 @@ export default {
name
}
})
return [ blockPayload, 0 ]
}
},
regenerators: {
json: (blockObject, helpers) => {
const
{ name } = blockObject.getVariable,
id = helpers.registerVariable(name)
return {
type: "io_variables_get",
fields: {