1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00
Commit Graph

16 Commits

Author SHA1 Message Date
Steve-Mcl
4d768fd236 ensure context get/set key is a string 2021-05-25 14:53:06 +01:00
Nick O'Leary
af636870d4
Add better error message if context file gets corrupted 2020-10-06 15:42:52 +01:00
Nick O'Leary
d57ec0cd53
Refactor lib/flows code to include initial router component 2020-09-29 12:19:26 +01:00
Nick O'Leary
97c771f93a
Ensure file context does not write 'undefined' to store
Fixes #2522
2020-04-08 11:32:39 +01:00
Nick O'Leary
84771f5864
Flows/subflows must preinitialise their context objects
Fixes #2513

If a node inside a subflow accessed its context object in its
constructor, the subflow-instance flow context would not yet
have been created. This would cause a place holder context
to get created on its behalf, but that place holder doesn't
have its parent set properly. This then breaks the usage
of $parent inside such a subflow.

This fix has changed it so flows (and subflows) create their
flow context as part of their initial creation. That ensures
it exists when individual nodes from the subflow are created,
allowing them to safely access their context.

This has also fixed a related issue where any attempt to use
$parent to access beyond the root parent would seemingly hang
as the callback was never being called. This would cause
messages to get stuck in flows. The fix ensures the callback
is used in the root context objects and undefined is returned.
2020-03-27 23:47:12 +00:00
Nick O'Leary
7d32636133
Improve file store error when cache disabled and sync api used
Closes #2406
2020-02-07 14:26:30 +00:00
Nick O'Leary
10077ae750
Use a more atomic process for writing context files
Fixes #2271
2019-08-21 16:54:26 +01:00
Nick O'Leary
9b938f6515
Fix default value handling on context array access
Fixes #2252
2019-08-06 15:55:25 +01:00
Nick O'Leary
4463a8e3b2
Add exportGlobalContextKeys to prevent exposing fgc keys 2019-03-04 16:10:39 +00:00
Hiroyasu Nishiyama
723e9b3cba make $parent access without key return undefined 2019-02-05 14:47:30 +09:00
Hiroyasu Nishiyama
596fbfb517 allow $parent access of flow context 2019-01-16 23:10:03 +09:00
Nick O'Leary
978f4ecc58
Ensure fs context cache is flushed on close
Fixes #2001
2018-12-13 12:46:19 +00:00
Nick O'Leary
8167608f04
Handle lookup of undefined property in Global context
Fixes #1978
2018-11-14 20:57:17 +00:00
Kazuhito Yokoi
ce014044ea Fix reference bug in message catalog 2018-10-17 15:43:09 +09:00
Nick O'Leary
2aae76c9bc
Merge branch 'dev' into repackage 2018-09-17 14:49:11 +01:00
Nick O'Leary
e57d8ba0ef
pull out editor-client and editor-api 2018-08-17 22:10:54 +01:00