3
0
mirror of https://github.com/britzl/monarch.git synced 2025-06-27 10:27:49 +02:00

Null fix when handling transitions

This commit is contained in:
Björn Ritzl 2017-09-25 18:01:40 +02:00
parent 9be4eeb87c
commit 149c50221c

View File

@ -79,8 +79,10 @@ function M.create(node)
-- Forward on_message calls here -- Forward on_message calls here
function instance.handle(message_id, message, sender) function instance.handle(message_id, message, sender)
if transitions[message_id] then
transitions[message_id](sender) transitions[message_id](sender)
end end
end
-- Specify the transition function when this node is transitioned -- Specify the transition function when this node is transitioned
-- to -- to