Skip to content

Commit

Permalink
Replaced type of SSO field to interface{} instead of string|bool
Browse files Browse the repository at this point in the history
…because it could be bool (if SSO is disabled) or string (if sso is enabled). (#26)
  • Loading branch information
disc authored Sep 6, 2022
1 parent 2083fcb commit 60a0963
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 15 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ test:
./tools/wait-for-it.sh localhost:27017 -- echo "mongodb is up"

# enables an api access for the pritunl user, updates an api token and secret
@docker exec -i tf_pritunl_acc_test mongo --quiet < ./tools/mongo.js
@docker exec -i tf_pritunl_acc_test mongo pritunl < ./tools/mongo.js

TF_ACC=1 \
PRITUNL_URL="https://localhost/" \
Expand Down
2 changes: 1 addition & 1 deletion internal/pritunl/user.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ type User struct {
ClientToClient bool `json:"client_to_client,omitempty"`
MacAddresses []string `json:"mac_addresses,omitempty"`
YubicoID string `json:"yubico_id,omitempty"`
SSO bool `json:"sso,omitempty"`
SSO interface{} `json:"sso,omitempty"`
BypassSecondary bool `json:"bypass_secondary,omitempty"`
Groups []string `json:"groups,omitempty"`
Audit bool `json:"audit,omitempty"`
Expand Down
14 changes: 1 addition & 13 deletions tools/mongo.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 60a0963

Please sign in to comment.