Skip to content

Commit

Permalink
FORGE-2586: AddonInstallCommand should validate only on execute
Browse files Browse the repository at this point in the history
  • Loading branch information
gastaldi committed Jan 21, 2016
1 parent 1e66664 commit 256ee40
Showing 1 changed file with 2 additions and 5 deletions.
Expand Up @@ -88,12 +88,9 @@ public void validate(UIValidationContext context)
String coordinate = (String) context.getCurrentInputComponent().getValue();
try
{
Furnace furnace = SimpleContainer.getFurnace(getClass().getClassLoader());
AddonDependencyResolver resolver = SimpleContainer
.getServices(getClass().getClassLoader(), AddonDependencyResolver.class).get();
CoordinateUtils.resolveCoordinate(coordinate, furnace.getVersion(), resolver);
AddonId.fromCoordinates(coordinate);
}
catch (Exception e)
catch (IllegalArgumentException e)
{
context.addValidationError(context.getCurrentInputComponent(), "\"" + coordinate
+ "\" is not a valid Addon coordinate");
Expand Down

0 comments on commit 256ee40

Please sign in to comment.