aboutsummaryrefslogtreecommitdiff
path: root/juick-www
diff options
context:
space:
mode:
Diffstat (limited to 'juick-www')
-rw-r--r--juick-www/build.gradle7
-rw-r--r--juick-www/src/main/java/com/juick/service/CloudflareCache.java1
-rw-r--r--juick-www/src/main/java/com/juick/www/controllers/Messages.java4
-rw-r--r--juick-www/src/main/java/com/juick/www/controllers/Settings.java1
-rw-r--r--juick-www/src/test/java/com/juick/www/WebAppTests.java8
5 files changed, 6 insertions, 15 deletions
diff --git a/juick-www/build.gradle b/juick-www/build.gradle
index fb7f8131..407f3402 100644
--- a/juick-www/build.gradle
+++ b/juick-www/build.gradle
@@ -19,12 +19,17 @@ task compileFrontend(type: YarnTask) {
}
apply plugin: 'war'
+apply plugin: 'org.springframework.boot'
dependencies {
- compile project(':juick-server-web')
compile project(':juick-server-jdbc')
+ compile 'com.github.ben-manes.caffeine:caffeine:2.6.2'
+ compile("org.springframework.boot:spring-boot-starter-cache")
compile ('org.springframework.boot:spring-boot-starter-security')
providedRuntime("org.springframework.boot:spring-boot-starter-tomcat")
+ providedRuntime 'com.h2database:h2:1.4.196'
+ runtime "commons-fileupload:commons-fileupload:1.3.3"
+
compile 'com.github.scribejava:scribejava-apis:5.3.0'
compile 'com.github.ooxi:serialized-php-parser:0.5.0'
compile 'com.sun.mail:javax.mail:1.6.1'
diff --git a/juick-www/src/main/java/com/juick/service/CloudflareCache.java b/juick-www/src/main/java/com/juick/service/CloudflareCache.java
index 5046f692..64e048dc 100644
--- a/juick-www/src/main/java/com/juick/service/CloudflareCache.java
+++ b/juick-www/src/main/java/com/juick/service/CloudflareCache.java
@@ -14,7 +14,6 @@ import org.springframework.web.util.UriComponents;
import org.springframework.web.util.UriComponentsBuilder;
import java.util.Arrays;
-import java.util.Collections;
public class CloudflareCache implements ApplicationListener<UserUpdatedEvent> {
private static final Logger logger = LoggerFactory.getLogger(CloudflareCache.class);
diff --git a/juick-www/src/main/java/com/juick/www/controllers/Messages.java b/juick-www/src/main/java/com/juick/www/controllers/Messages.java
index ea66e711..ce21f97d 100644
--- a/juick-www/src/main/java/com/juick/www/controllers/Messages.java
+++ b/juick-www/src/main/java/com/juick/www/controllers/Messages.java
@@ -43,12 +43,8 @@ import javax.inject.Inject;
import javax.servlet.http.HttpServletRequest;
import java.io.IOException;
import java.net.URLEncoder;
-import java.time.Instant;
-import java.time.LocalDateTime;
-import java.time.ZoneOffset;
import java.util.ArrayList;
import java.util.List;
-import java.util.function.BooleanSupplier;
import java.util.stream.Collectors;
/**
diff --git a/juick-www/src/main/java/com/juick/www/controllers/Settings.java b/juick-www/src/main/java/com/juick/www/controllers/Settings.java
index 141c9e2c..ffc66841 100644
--- a/juick-www/src/main/java/com/juick/www/controllers/Settings.java
+++ b/juick-www/src/main/java/com/juick/www/controllers/Settings.java
@@ -40,7 +40,6 @@ import javax.mail.Session;
import javax.mail.Transport;
import javax.mail.internet.InternetAddress;
import javax.mail.internet.MimeMessage;
-import javax.servlet.ServletException;
import javax.servlet.http.Cookie;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
diff --git a/juick-www/src/test/java/com/juick/www/WebAppTests.java b/juick-www/src/test/java/com/juick/www/WebAppTests.java
index 7aa0a515..8752a25e 100644
--- a/juick-www/src/test/java/com/juick/www/WebAppTests.java
+++ b/juick-www/src/test/java/com/juick/www/WebAppTests.java
@@ -37,7 +37,6 @@ import com.mitchellbosecke.pebble.PebbleEngine;
import com.mitchellbosecke.pebble.error.PebbleException;
import com.mitchellbosecke.pebble.template.PebbleTemplate;
import org.apache.commons.text.StringEscapeUtils;
-import org.eclipse.jetty.websocket.common.message.MessageAppender;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
@@ -46,22 +45,15 @@ import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.mock.mockito.MockBean;
-import org.springframework.context.annotation.Bean;
-import org.springframework.context.annotation.Configuration;
import org.springframework.core.io.ClassPathResource;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.mock.web.MockMultipartFile;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.TestPropertySource;
-import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.test.context.junit4.SpringRunner;
-import org.springframework.test.context.web.WebAppConfiguration;
import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.MvcResult;
-import org.springframework.test.web.servlet.htmlunit.MockMvcWebClientBuilder;
-import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.util.FileSystemUtils;
-import org.springframework.web.context.WebApplicationContext;
import javax.inject.Inject;
import javax.servlet.http.Cookie;