From 30ed52be62193cf840d147acefc2f407a1409259 Mon Sep 17 00:00:00 2001 From: pancx Date: Fri, 3 Jan 2025 17:15:11 +0800 Subject: [PATCH] [#5960] fix(CLI): Add register and link commands to CLI for model Fix some error. --- .../java/org/apache/gravitino/cli/GravitinoCommandLine.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clients/cli/src/main/java/org/apache/gravitino/cli/GravitinoCommandLine.java b/clients/cli/src/main/java/org/apache/gravitino/cli/GravitinoCommandLine.java index a16454af3d6..3a9322d010e 100644 --- a/clients/cli/src/main/java/org/apache/gravitino/cli/GravitinoCommandLine.java +++ b/clients/cli/src/main/java/org/apache/gravitino/cli/GravitinoCommandLine.java @@ -1180,8 +1180,6 @@ private void handleModelCommand() { } String model = name.getModelName(); - String[] alias = line.getOptionValues(GravitinoOptions.ALIAS); - String uri = line.getOptionValue(GravitinoOptions.URI); if (model == null) missingEntities.add(CommandEntities.MODEL); checkEntities(missingEntities); @@ -1204,6 +1202,8 @@ private void handleModelCommand() { break; case CommandActions.UPDATE: + String[] alias = line.getOptionValues(GravitinoOptions.ALIAS); + String uri = line.getOptionValue(GravitinoOptions.URI); if (uri == null) { System.err.println(ErrorMessages.MISSING_URI); Main.exit(-1);