Skip to content

Commit

Permalink
bug in saving default vulns
Browse files Browse the repository at this point in the history
  • Loading branch information
summitt committed Aug 9, 2024
1 parent 81a0e10 commit 24aceea
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions release.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#release configuration
#Thu Aug 08 16:19:21 PDT 2024
completedPhase=generate-release-poms
#Thu Aug 08 16:22:23 PDT 2024
completedPhase=end-release
exec.activateProfiles=github
exec.additionalArguments=-Dmaven.javadoc.skip\=true -Dmaven.test.skipTests\=true -Dmaven.test.skip\=true
exec.pomFileName=pom.xml
Expand Down
2 changes: 1 addition & 1 deletion src/com/fuse/dao/query/VulnerabilityQueries.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public class VulnerabilityQueries {
public static DefaultVulnerability getDefaultVulnerability(EntityManager em, String name) {
name = FSUtils.sanitizeMongo(name);
name = escapeRegex(name);
String query = "{'name':{'$regex' : '^.*" + name + ".*$', '$options' : 'i'}}";
String query = "{'name':{'$regex' : '^" + name + "$', '$options' : 'i'}}";
query = query.replace("'", "\"");
return (DefaultVulnerability) em.createNativeQuery(query, DefaultVulnerability.class).getResultList().stream()
.findFirst().orElse(null);
Expand Down

0 comments on commit 24aceea

Please sign in to comment.