diff --git a/examples/pubsub.py b/examples/pubsub.py index cf1a2f8..962c2a1 100644 --- a/examples/pubsub.py +++ b/examples/pubsub.py @@ -1,4 +1,4 @@ -# LTK - Copyright 2024 - All Rights Reserved - chrislaffra.com - See LICENSE +# LTK - Copyright 2024 - All Rights Reserved - chrislaffra.com - See LICENSE import ltk import random @@ -6,7 +6,7 @@ # Workers only work when server sets CORS, COOP, COEP headers # See https://jeff.glass/post/whats-new-pyscript-2023-11-1/ for more details -worker = XWorker("/examples/worker.py", config="/examples/worker.toml", type="micropython") +worker = XWorker("./examples/worker.py", config="./examples/worker.toml", type="micropython") fan = ltk.Preformatted("") @@ -20,12 +20,12 @@ def publish(event=None): message = random.choice([ "Subscribe!\n", "Like!\n", "Share!\n", "Pay me!\n", "Repost!\n" - ]) + ]) ltk.publish( "Influencer", # the sender "Fan", # the intended receiver "message", # the subscription topic - message # the message to send + message # the message to send ) def create():