blob: a03733a8af7588d1ef43f61a1d5c732ad9b006f0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
package eduvpn
type EduVPNState struct {
// The struct used for oauth
OAuth *EduVPNOauth
// The endpoints
Endpoints *EduVPNEndpoints
// Info passed by the client
Name string
Server string
}
func Register(name string, server string) *EduVPNState {
state := &EduVPNState{Name: name, Server: server}
endpoints, err := APIGetEndpoints(state)
if err != nil {
panic(err)
}
state.Endpoints = endpoints
return state
}
|