From b86945d86dad021087438ca748685a2c5d16a712 Mon Sep 17 00:00:00 2001 From: Shaopeng Lin Date: Mon, 2 Oct 2023 16:43:25 +0100 Subject: [PATCH] Fix create relation bug --- pkg/topo/create.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/topo/create.go b/pkg/topo/create.go index 941fcb0e..47c2da9d 100644 --- a/pkg/topo/create.go +++ b/pkg/topo/create.go @@ -57,7 +57,7 @@ func runCreateEntityCommand(cmd *cobra.Command, args []string) error { func runCreateRelationCommand(cmd *cobra.Command, args []string) error { kindID, _ := cmd.Flags().GetString("kind") - return createObject(topoapi.NewRelation(topoapi.ID(args[0]), topoapi.ID(args[2]), topoapi.ID(kindID)), cmd) + return createObject(topoapi.NewRelation(topoapi.ID(args[0]), topoapi.ID(args[1]), topoapi.ID(kindID)), cmd) } func runCreateKindCommand(cmd *cobra.Command, args []string) error {