diff options
author | Julien Eluard <[email protected]> | 2012-03-15 15:32:51 -0300 |
---|---|---|
committer | Julien Eluard <[email protected]> | 2012-03-15 15:32:51 -0300 |
commit | b2f4fa401dda9139eafd69bf35d4a9c39a4cee8e (patch) | |
tree | 932746c8dbfec5f8335c3628aa5488216451d963 /enforcer-rule/src/main/java/org | |
parent | b3e250d7906d97680bb0f4f5fa09ad1f7a56686c (diff) |
Do not throw exception when no previous artifacts exist.
Diffstat (limited to 'enforcer-rule/src/main/java/org')
-rwxr-xr-x | enforcer-rule/src/main/java/org/semver/enforcer/AbstractEnforcerRule.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/enforcer-rule/src/main/java/org/semver/enforcer/AbstractEnforcerRule.java b/enforcer-rule/src/main/java/org/semver/enforcer/AbstractEnforcerRule.java index 4f5a6f6..4eae532 100755 --- a/enforcer-rule/src/main/java/org/semver/enforcer/AbstractEnforcerRule.java +++ b/enforcer-rule/src/main/java/org/semver/enforcer/AbstractEnforcerRule.java @@ -135,7 +135,9 @@ public abstract class AbstractEnforcerRule implements EnforcerRule { validateArtifact(previousArtifact); validateArtifact(currentArtifact); } catch (Exception e) { - throw new EnforcerRuleException("Exception while accessing artifacts", e); + helper.getLog().warn("Exception while accessing artifacts; skipping check.", e); + return; + //throw new EnforcerRuleException("Exception while accessing artifacts", e); } final Version previous = Version.parse(previousArtifact.getVersion()); |