Skip to content
This repository was archived by the owner on Feb 25, 2026. It is now read-only.

Commit c52591e

Browse files
author
Karan Kajla
committed
Use the correct arg to get the specified context in the FGA query command
1 parent 5d95c18 commit c52591e

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

internal/cmd/fga.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -559,9 +559,9 @@ var queryCmd = &cobra.Command{
559559
}
560560
var policyContext map[string]interface{}
561561
if len(args) > 1 {
562-
err := json.Unmarshal([]byte(args[3]), &policyContext)
562+
err := json.Unmarshal([]byte(args[1]), &policyContext)
563563
if err != nil {
564-
return errors.Errorf("invalid context: %s", args[3])
564+
return errors.Errorf("invalid context: %s", args[1])
565565
}
566566
}
567567

0 commit comments

Comments
 (0)