#2486 WampClient needs pyro.plcobj before registration calls. #2486
authordporopat <denis.poropat@smarteh.si>
Wed, 18 Apr 2018 10:40:16 +0200
branch#2486
changeset 2200 6417f5b59eff
parent 2199 8fd73c6c8aa9
child 2201 4e511f5aad19
#2486 WampClient needs pyro.plcobj before registration calls.
Beremiz_service.py
--- a/Beremiz_service.py	Wed Apr 11 10:53:48 2018 +0200
+++ b/Beremiz_service.py	Wed Apr 18 10:40:16 2018 +0200
@@ -620,10 +620,9 @@
         try:
             _wampconf = WC.LoadWampClientConf(wampconf)
             if _wampconf:
-                if _wampconf["url"]:  # TODO : test more ?
+                WC.SetServer(pyroserver)
+                if _wampconf.get("url", None):  # TODO : test more ?
                     WC.RegisterWampClient(wampconf, wampsecret)
-                    pyruntimevars["wampsession"] = WC.GetSession
-                    WC.SetServer(pyroserver)
                 else:
                     raise Exception(_("WAMP config is incomplete."))
             else: