Skip to content

Commit

Permalink
catch if endpoints are unknown
Browse files Browse the repository at this point in the history
  • Loading branch information
sneaker182 committed Apr 21, 2015
1 parent d38ab32 commit f97696b
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/main/java/ilarkesto/di/app/WebApplicationStarter.java
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
/*
* Copyright 2011 Witoslaw Koczewsi <[email protected]>, Artjom Kochtchi
*
*
* This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero
* General Public License as published by the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the
* implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
* License for more details.
*
*
* You should have received a copy of the GNU General Public License along with this program. If not, see
* <http://www.gnu.org/licenses/>.
*/
Expand Down Expand Up @@ -36,7 +36,11 @@ public static AWebApplication startWebApplication(String applicationClassName, S
beanProvider.put("serverInfo", servletContext.getServerInfo());
beanProvider.put("servletContextName", servletContext.getServletContextName());
beanProvider.put("servletContextRealPath", servletContext.getRealPath("/"));
beanProvider.put("serverEndpoints", Servlet.getEndpoints());
try {
beanProvider.put("serverEndpoints", Servlet.getEndpoints());
} catch (Exception e) {
LOG.warn(e);
}
try {
result = startApplication((Class<? extends AWebApplication>) Class.forName(applicationClassName),
beanProvider);
Expand Down

0 comments on commit f97696b

Please sign in to comment.