Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions omod/src/main/java/org/openmrs/web/WebComponentRegistrar.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,16 @@
import org.springframework.stereotype.Component;
import org.springframework.web.context.ServletContextAware;

//Added
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

@Component
public class WebComponentRegistrar implements ServletContextAware {


//Added
private static final Logger log = LoggerFactory.getLogger(WebComponentRegistrar.class);

@Override
public void setServletContext(ServletContext servletContext) {

Expand Down Expand Up @@ -61,7 +68,9 @@ public void setServletContext(ServletContext servletContext) {
//This happens on running openmrs after InitializationFilter or UpdateFilter
//hence requiring a restart to see any page other than index.htm
//After a restart, all mappings will then happen within Listener.contextInitialized()
ex.printStackTrace();

//Replaced
log.error("Error registering web component", ex);
}
}

Expand Down
Loading