From 00ffd7ddb0f332dd2d416187267955346bfb9d8a Mon Sep 17 00:00:00 2001 From: j2blake Date: Mon, 26 Sep 2011 13:33:45 +0000 Subject: [PATCH] NIHVIVO-336 Modify the listeners to use StartupStatus instead of AbortStartup --- .../policy/SelfEditorRelationshipPolicy.java | 20 ++++--------------- 1 file changed, 4 insertions(+), 16 deletions(-) diff --git a/src/edu/cornell/mannlib/vivo/auth/policy/SelfEditorRelationshipPolicy.java b/src/edu/cornell/mannlib/vivo/auth/policy/SelfEditorRelationshipPolicy.java index cbbabc2b..eb4bda55 100644 --- a/src/edu/cornell/mannlib/vivo/auth/policy/SelfEditorRelationshipPolicy.java +++ b/src/edu/cornell/mannlib/vivo/auth/policy/SelfEditorRelationshipPolicy.java @@ -23,7 +23,6 @@ import edu.cornell.mannlib.vitro.webapp.auth.policy.specialrelationships.Abstrac import edu.cornell.mannlib.vitro.webapp.auth.requestedAction.ifaces.RequestedAction; import edu.cornell.mannlib.vitro.webapp.auth.requestedAction.propstmt.AbstractDataPropertyAction; import edu.cornell.mannlib.vitro.webapp.auth.requestedAction.propstmt.AbstractObjectPropertyAction; -import edu.cornell.mannlib.vitro.webapp.servlet.setup.AbortStartup; /** * Permit self-editors to edit the properties of classes with which they share a @@ -366,22 +365,11 @@ public class SelfEditorRelationshipPolicy extends AbstractRelationshipPolicy public void contextInitialized(ServletContextEvent sce) { ServletContext ctx = sce.getServletContext(); - if (AbortStartup.isStartupAborted(ctx)) { - return; - } + OntModel ontModel = (OntModel) sce.getServletContext() + .getAttribute("jenaOntModel"); - try { - OntModel ontModel = (OntModel) sce.getServletContext() - .getAttribute("jenaOntModel"); - - ServletPolicyList.addPolicy(ctx, - new SelfEditorRelationshipPolicy(ctx, ontModel)); - } catch (Exception e) { - log.error("could not run " + this.getClass().getSimpleName() - + ": " + e); - AbortStartup.abortStartup(ctx); - throw new RuntimeException(e); - } + ServletPolicyList.addPolicy(ctx, new SelfEditorRelationshipPolicy( + ctx, ontModel)); } @Override