Skip to content

Commit

Permalink
[chore] Move openai log message to proper function (#3105)
Browse files Browse the repository at this point in the history
  • Loading branch information
mcastorina authored Jul 26, 2024
1 parent cf221e8 commit 63568b0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/analyzer/analyzers/openai/openai.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ func AnalyzeAndPrintPermissions(cfg *config.Config, apiKey string) {
color.Red("[x] %s", err.Error())
return
}
color.Green("[!] Valid OpenAI Token\n\n")

printUserData(data.me)
if data.isAdmin {
Expand Down Expand Up @@ -237,7 +238,6 @@ func getUserData(cfg *config.Config, key string) (MeJSON, error) {
if resp.StatusCode != 200 {
return meJSON, fmt.Errorf("invalid OpenAI token")
}
color.Green("[!] Valid OpenAI Token\n\n")

// Marshall me into meJSON struct
if err := json.Unmarshal(me, &meJSON); err != nil {
Expand Down

0 comments on commit 63568b0

Please sign in to comment.