Skip to content

Commit

Permalink
Merge pull request #18 from GluuFederation/issues_17
Browse files Browse the repository at this point in the history
fix(oxtrust-api): file based tr is not updating with rest call
  • Loading branch information
yurem authored Nov 14, 2024
2 parents bba3798 + f2ebffc commit 813cf1c
Showing 1 changed file with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -814,12 +814,17 @@ private boolean saveSpMetaDataFileSourceTypeFile(GluuSAMLTrustRelationship trus
// Admin doesn't provide new file. Check if we already has this file
String filePath = shibboleth3ConfService.getSpMetadataFilePath(spMetadataFileName);
if (filePath == null) {
logger.debug("The trust relationship {} has an invalid Metadata file storage path", trustRelationship.getInum());
return false;
}

File file = new File(filePath);
if (!file.exists()) {
return false;
if (shibboleth3ConfService.isLocalDocumentStoreType()) {
File file = new File(filePath);
if (!file.exists()) {
logger.debug("The trust relationship {} metadata used local storage but the SP metadata file `{}` was not found",
trustRelationship.getInum(),filePath);
return false;
}
}

// File already exist
Expand Down

0 comments on commit 813cf1c

Please sign in to comment.