aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/MainModule.java
diff options
context:
space:
mode:
authorDaniel <djr2468@gmail.com>2023-04-05 21:45:37 +0100
committerDaniel <djr2468@gmail.com>2023-04-05 21:45:37 +0100
commita710ddd5ad336cd45d3a0e69f13985db840763dc (patch)
tree4420bfcc613afbdd578735ff44858d910c4343b3 /src/main/java/org/traccar/MainModule.java
parent1ecd7efca41344f29f8caa42fc6caaed8c7294a1 (diff)
downloadtrackermap-server-a710ddd5ad336cd45d3a0e69f13985db840763dc.tar.gz
trackermap-server-a710ddd5ad336cd45d3a0e69f13985db840763dc.tar.bz2
trackermap-server-a710ddd5ad336cd45d3a0e69f13985db840763dc.zip
Review changes 2
Diffstat (limited to 'src/main/java/org/traccar/MainModule.java')
-rw-r--r--src/main/java/org/traccar/MainModule.java12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/main/java/org/traccar/MainModule.java b/src/main/java/org/traccar/MainModule.java
index 220798767..4db6e0e32 100644
--- a/src/main/java/org/traccar/MainModule.java
+++ b/src/main/java/org/traccar/MainModule.java
@@ -96,6 +96,7 @@ import javax.ws.rs.client.Client;
import javax.ws.rs.client.ClientBuilder;
import java.io.IOException;
import java.net.InetAddress;
+import java.net.URISyntaxException;
import java.net.UnknownHostException;
import java.net.http.HttpClient;
import java.util.Properties;
@@ -176,11 +177,12 @@ public class MainModule extends AbstractModule {
@Singleton
@Provides
public static OpenIdProvider provideOpenIDProvider(
- Config config, LoginService loginService, ObjectMapper objectMapper) throws InterruptedException, IOException {
- if (config.hasKey(Keys.OPENID_CLIENT_ID)) {
- return new OpenIdProvider(config, loginService, HttpClient.newHttpClient(), objectMapper);
- }
- return null;
+ Config config, LoginService loginService, ObjectMapper objectMapper
+ ) throws InterruptedException, IOException, URISyntaxException {
+ if (config.hasKey(Keys.OPENID_CLIENT_ID)) {
+ return new OpenIdProvider(config, loginService, HttpClient.newHttpClient(), objectMapper);
+ }
+ return null;
}
@Provides