Helped toward fixing issue 228: ButterflyServlet already tracks the ServletConfig, so there's no need for RefineServlet to do that, too.

Importing archive files has another big problem at the moment: namely, even if the many files in a single archive file share several columns, they still cause columns with the same names to be over and over again as each file gets imported. This is because individual importer was written with the assumption that it imports into an empty project with no column.

git-svn-id: http://google-refine.googlecode.com/svn/trunk@1918 7d457c2a-affb-35e4-300a-418c747d4874
This commit is contained in:
David Huynh 2010-11-21 02:58:15 +00:00
parent 09fa36198c
commit c496f1e941

View File

@ -94,8 +94,6 @@ public class RefineServlet extends Butterfly {
}
}
protected ServletConfig config;
@Override
public void init() throws ServletException {
super.init();
@ -150,8 +148,6 @@ public class RefineServlet extends Butterfly {
ProjectManager.singleton = null;
}
this.config = null;
logger.trace("< destroy");
super.destroy();
@ -208,7 +204,7 @@ public class RefineServlet extends Butterfly {
public File getTempDir() {
if (tempDir == null) {
File tempDir = (File) this.config.getServletContext().getAttribute(JAVAX_SERVLET_CONTEXT_TEMPDIR);
File tempDir = (File) _config.getServletContext().getAttribute(JAVAX_SERVLET_CONTEXT_TEMPDIR);
if (tempDir == null) {
throw new RuntimeException("This app server doesn't support temp directories");
}