Skip to content

Commit

Permalink
check if endpoint is empty
Browse files Browse the repository at this point in the history
  • Loading branch information
cemklc committed May 5, 2021
1 parent eece20d commit e03746a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/main/java/io/antmedia/AntMediaApplicationAdapter.java
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,8 @@ else if (socialEndpointCredentials.getServiceName().equals(YOUTUBE))
storageClient.setRegion(appSettings.getS3RegionName());
storageClient.setAccessKey(appSettings.getS3AccessKey());
storageClient.setSecretKey(appSettings.getS3SecretKey());
storageClient.setEndpoint(appSettings.getS3Endpoint());
if (appSettings.getS3Endpoint() != null){
storageClient.setEndpoint(appSettings.getS3Endpoint());}
}
logger.info("{} started", app.getName());

Expand Down Expand Up @@ -1538,7 +1539,10 @@ private void updateAppSettingsBean(AppSettings appSettings, AppSettings newSetti
storageClient.setAccessKey(newSettings.getS3AccessKey());
storageClient.setSecretKey(newSettings.getS3SecretKey());
storageClient.setRegion(newSettings.getS3RegionName());
storageClient.setEndpoint(newSettings.getS3Endpoint());

if (appSettings.getS3Endpoint() != null){
storageClient.setEndpoint(appSettings.getS3Endpoint());}

}else{
appSettings.setS3AccessKey("");
appSettings.setS3SecretKey("");
Expand Down

0 comments on commit e03746a

Please sign in to comment.