From 5887d925486e7ce650c3440de6cd29dd2240e929 Mon Sep 17 00:00:00 2001 From: jwijenbergh Date: Tue, 15 Mar 2022 16:12:48 +0100 Subject: Add callback state change and simplify wrappers The python wrapper contained lots of code that should not be exposed. The other wrappers I will update later --- src/state.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/state.go') diff --git a/src/state.go b/src/state.go index 5d054bb..be85a45 100644 --- a/src/state.go +++ b/src/state.go @@ -13,7 +13,7 @@ type EduVPNState struct { OAuthSession *EduVPNOAuthSession } -func Register(state *EduVPNState, name string, server string) error { +func Register(state *EduVPNState, name string, server string, stateCallback func(string, string)) error { state.Name = name state.Server = server @@ -24,6 +24,7 @@ func Register(state *EduVPNState, name string, server string) error { } state.Endpoints = endpoints + stateCallback("START", "REGISTER") return nil } -- cgit v1.2.3